* [Buildroot] [PATCH v3] pyrex: new package
@ 2014-03-15 22:00 mlweber1 at rockwellcollins.com
2014-03-15 22:25 ` Yann E. MORIN
2014-03-29 11:03 ` Thomas Petazzoni
0 siblings, 2 replies; 4+ messages in thread
From: mlweber1 at rockwellcollins.com @ 2014-03-15 22:00 UTC (permalink / raw)
To: buildroot
From: Matt Weber <mlweber1@rockwellcollins.com>
Pyrex is a language that allows you to mix python and C code in a
single .pyx description file. This file is then rendered into C
code by the pyrexc host tool. That C file then can be used within
an application build or as part of the normal distutils build
process used to build a Python extension module. In my use case,
I was using buildroot to build a python extension module.
I will be submitting the pypcap package as the application that uses
this tool to generate an extension module for the libpcap library.
Signed-off-by: Matt Weber <mlweber1@rockwellcollins.com>
---
Changes v2 -> v3:
- Moved menu entry under host utilities menu (Suggested by Yann)
- Updated description and included a description above (Suggested by Yann)
Changes v1 -> v2:
- Converted to a host only pkg as this pkg provides generated
C code that an application would use from a sysroot
(not on target). (Suggested by Thomas)
---
package/Config.in.host | 1 +
package/python-pyrex/Config.in.host | 10 ++++++++++
package/python-pyrex/python-pyrex.mk | 15 +++++++++++++++
3 files changed, 26 insertions(+)
create mode 100644 package/python-pyrex/Config.in.host
create mode 100644 package/python-pyrex/python-pyrex.mk
diff --git a/package/Config.in.host b/package/Config.in.host
index ac6091f..b8706cd 100644
--- a/package/Config.in.host
+++ b/package/Config.in.host
@@ -12,6 +12,7 @@ source "package/mtools/Config.in.host"
source "package/omap-u-boot-utils/Config.in.host"
source "package/openocd/Config.in.host"
source "package/parted/Config.in.host"
+source "package/python-pyrex/Config.in.host"
source "package/sam-ba/Config.in.host"
source "package/squashfs/Config.in.host"
source "package/sunxi-tools/Config.in.host"
diff --git a/package/python-pyrex/Config.in.host b/package/python-pyrex/Config.in.host
new file mode 100644
index 0000000..4edeb38
--- /dev/null
+++ b/package/python-pyrex/Config.in.host
@@ -0,0 +1,10 @@
+config BR2_PACKAGE_HOST_PYTHON_PYREX
+ bool "python-pyrex"
+ depends on BR2_PACKAGE_PYTHON
+ help
+ Pyrex is a language for writing mixed Python and C
+ extension modules. This tool is invoked as part of
+ the build process to generate C code from a .pyx
+ description file.
+
+ http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/
diff --git a/package/python-pyrex/python-pyrex.mk b/package/python-pyrex/python-pyrex.mk
new file mode 100644
index 0000000..73cb163
--- /dev/null
+++ b/package/python-pyrex/python-pyrex.mk
@@ -0,0 +1,15 @@
+################################################################################
+#
+# python-pyrex
+#
+################################################################################
+
+PYTHON_PYREX_VERSION = 0.9.9
+PYTHON_PYREX_SOURCE = Pyrex-$(PYTHON_PYREX_VERSION).tar.gz
+PYTHON_PYREX_SITE = http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/
+PYTHON_PYREX_DEPENDENCIES = host-python
+PYTHON_PYREX_LICENSE = Apache-v2
+PYTHON_PYREX_LICENSE_FILES = LICENSE.txt
+PYTHON_PYREX_SETUP_TYPE = distutils
+
+$(eval $(host-python-package))
--
1.7.9.5
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH v3] pyrex: new package
2014-03-15 22:00 [Buildroot] [PATCH v3] pyrex: new package mlweber1 at rockwellcollins.com
@ 2014-03-15 22:25 ` Yann E. MORIN
2014-03-29 11:03 ` Thomas Petazzoni
1 sibling, 0 replies; 4+ messages in thread
From: Yann E. MORIN @ 2014-03-15 22:25 UTC (permalink / raw)
To: buildroot
Matt, All,
On 2014-03-15 17:00 -0500, mlweber1 at rockwellcollins.com spake thusly:
> From: Matt Weber <mlweber1@rockwellcollins.com>
>
> Pyrex is a language that allows you to mix python and C code in a
> single .pyx description file. This file is then rendered into C
> code by the pyrexc host tool. That C file then can be used within
> an application build or as part of the normal distutils build
> process used to build a Python extension module.
Great description! Thanks! :-)
> In my use case,
> I was using buildroot to build a python extension module.
>
> I will be submitting the pypcap package as the application that uses
> this tool to generate an extension module for the libpcap library.
The two sentences above do not really belong to a commit log. Personal
experience may go after a --- line, if needed, as do plans about a
future submission.
> Signed-off-by: Matt Weber <mlweber1@rockwellcollins.com>
> ---
> Changes v2 -> v3:
> - Moved menu entry under host utilities menu (Suggested by Yann)
> - Updated description and included a description above (Suggested by Yann)
>
> Changes v1 -> v2:
> - Converted to a host only pkg as this pkg provides generated
> C code that an application would use from a sysroot
> (not on target). (Suggested by Thomas)
> ---
> package/Config.in.host | 1 +
> package/python-pyrex/Config.in.host | 10 ++++++++++
> package/python-pyrex/python-pyrex.mk | 15 +++++++++++++++
> 3 files changed, 26 insertions(+)
> create mode 100644 package/python-pyrex/Config.in.host
> create mode 100644 package/python-pyrex/python-pyrex.mk
>
> diff --git a/package/Config.in.host b/package/Config.in.host
> index ac6091f..b8706cd 100644
> --- a/package/Config.in.host
> +++ b/package/Config.in.host
> @@ -12,6 +12,7 @@ source "package/mtools/Config.in.host"
> source "package/omap-u-boot-utils/Config.in.host"
> source "package/openocd/Config.in.host"
> source "package/parted/Config.in.host"
> +source "package/python-pyrex/Config.in.host"
> source "package/sam-ba/Config.in.host"
> source "package/squashfs/Config.in.host"
> source "package/sunxi-tools/Config.in.host"
> diff --git a/package/python-pyrex/Config.in.host b/package/python-pyrex/Config.in.host
> new file mode 100644
> index 0000000..4edeb38
> --- /dev/null
> +++ b/package/python-pyrex/Config.in.host
> @@ -0,0 +1,10 @@
> +config BR2_PACKAGE_HOST_PYTHON_PYREX
> + bool "python-pyrex"
Like for all other host utils we expose in that sub-menu, the prompt
should start with 'host ' as I said in my previous mail. So that should
be:
bool "host python-pyrex"
Otherwise, looks good. :-)
Care to re-send with that fixed (unless Peter beats you to it when he
applies it) ?
Regards,
Yann E. MORIN.
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH v3] pyrex: new package
2014-03-15 22:00 [Buildroot] [PATCH v3] pyrex: new package mlweber1 at rockwellcollins.com
2014-03-15 22:25 ` Yann E. MORIN
@ 2014-03-29 11:03 ` Thomas Petazzoni
2014-03-31 13:01 ` mlweber1 at rockwellcollins.com
1 sibling, 1 reply; 4+ messages in thread
From: Thomas Petazzoni @ 2014-03-29 11:03 UTC (permalink / raw)
To: buildroot
Matt,
On Sat, 15 Mar 2014 17:00:30 -0500, mlweber1 at rockwellcollins.com wrote:
> diff --git a/package/python-pyrex/Config.in.host b/package/python-pyrex/Config.in.host
> new file mode 100644
> index 0000000..4edeb38
> --- /dev/null
> +++ b/package/python-pyrex/Config.in.host
> @@ -0,0 +1,10 @@
> +config BR2_PACKAGE_HOST_PYTHON_PYREX
> + bool "python-pyrex"
> + depends on BR2_PACKAGE_PYTHON
Is it actually really needed to have this host package visible in
menuconfig? python-pyrex is really a tool to generate code, so it
should be used by other packages as a dependency, and does not
necessarily need to be exposed in menuconfig.
To me, host-python-pyrex is a little bit like host-bison or host-flex:
useful as a dependency of another package, but not really useful as a
visible host package in menuconfig.
Would you agree if I removed this option when applying your patch?
Best regards,
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH v3] pyrex: new package
2014-03-29 11:03 ` Thomas Petazzoni
@ 2014-03-31 13:01 ` mlweber1 at rockwellcollins.com
0 siblings, 0 replies; 4+ messages in thread
From: mlweber1 at rockwellcollins.com @ 2014-03-31 13:01 UTC (permalink / raw)
To: buildroot
Thomas,
Thomas Petazzoni <thomas.petazzoni@free-electrons.com> wrote on 03/29/2014
06:03:25 AM:
> From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
> To: mlweber1 at rockwellcollins.com
> Cc: buildroot at busybox.net
> Date: 03/29/2014 06:03 AM
> Subject: Re: [Buildroot] [PATCH v3] pyrex: new package
>
> Matt,
>
> On Sat, 15 Mar 2014 17:00:30 -0500, mlweber1 at rockwellcollins.com wrote:
>
> > diff --git a/package/python-pyrex/Config.in.host b/package/python-
> pyrex/Config.in.host
> > new file mode 100644
> > index 0000000..4edeb38
> > --- /dev/null
> > +++ b/package/python-pyrex/Config.in.host
> > @@ -0,0 +1,10 @@
> > +config BR2_PACKAGE_HOST_PYTHON_PYREX
> > + bool "python-pyrex"
> > + depends on BR2_PACKAGE_PYTHON
>
> Is it actually really needed to have this host package visible in
> menuconfig? python-pyrex is really a tool to generate code, so it
> should be used by other packages as a dependency, and does not
> necessarily need to be exposed in menuconfig.
>
> To me, host-python-pyrex is a little bit like host-bison or host-flex:
> useful as a dependency of another package, but not really useful as a
> visible host package in menuconfig.
>
> Would you agree if I removed this option when applying your patch?
Yeah that makes sense. I'll update the patch set.
Thanks for the feedback!
Matt
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-03-31 13:01 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-15 22:00 [Buildroot] [PATCH v3] pyrex: new package mlweber1 at rockwellcollins.com
2014-03-15 22:25 ` Yann E. MORIN
2014-03-29 11:03 ` Thomas Petazzoni
2014-03-31 13:01 ` mlweber1 at rockwellcollins.com
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox