* [Buildroot] [PATCH 1/1] python-cython: new package
@ 2017-11-06 20:35 Joseph Kogut
2017-11-25 12:45 ` Thomas Petazzoni
0 siblings, 1 reply; 4+ messages in thread
From: Joseph Kogut @ 2017-11-06 20:35 UTC (permalink / raw)
To: buildroot
Signed-off-by: Joseph Kogut <joseph.kogut@gmail.com>
---
DEVELOPERS | 1 +
package/Config.in.host | 1 +
package/python-cython/Config.in.host | 7 +++++++
package/python-cython/python-cython.hash | 6 ++++++
package/python-cython/python-cython.mk | 16 ++++++++++++++++
5 files changed, 31 insertions(+)
create mode 100644 package/python-cython/Config.in.host
create mode 100644 package/python-cython/python-cython.hash
create mode 100644 package/python-cython/python-cython.mk
diff --git a/DEVELOPERS b/DEVELOPERS
index c651bf26fa..faeab79d63 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -788,6 +788,7 @@ F: board/qemu/ppc64le-pseries/
F: configs/qemu_ppc64le_pseries_defconfig
N: Joseph Kogut <joseph.kogut@gmail.com>
+F: package/python-cython/
F: package/python-websockets/
N: Johan Derycke <johanderycke@gmail.com>
diff --git a/package/Config.in.host b/package/Config.in.host
index 3755310de4..a15a11b07d 100644
--- a/package/Config.in.host
+++ b/package/Config.in.host
@@ -38,6 +38,7 @@ menu "Host utilities"
source "package/pkgconf/Config.in.host"
source "package/pru-software-support/Config.in.host"
source "package/pwgen/Config.in.host"
+ source "package/python-cython/Config.in.host"
source "package/python-lxml/Config.in.host"
source "package/python-six/Config.in.host"
source "package/qemu/Config.in.host"
diff --git a/package/python-cython/Config.in.host b/package/python-cython/Config.in.host
new file mode 100644
index 0000000000..69d32d5ab3
--- /dev/null
+++ b/package/python-cython/Config.in.host
@@ -0,0 +1,7 @@
+config BR2_PACKAGE_HOST_PYTHON_CYTHON
+ bool "host python-cython"
+ help
+ The Cython compiler for writing C extensions for the Python
+ language.
+
+ http://cython.org/
diff --git a/package/python-cython/python-cython.hash b/package/python-cython/python-cython.hash
new file mode 100644
index 0000000000..33b6bb6bbf
--- /dev/null
+++ b/package/python-cython/python-cython.hash
@@ -0,0 +1,6 @@
+# md5 from https://pypi.python.org/pypi/Cython/json, sha256 locally computed
+md5 6149238287d662bd5d5e572482252493 Cython-0.27.3.tar.gz
+sha256 6a00512de1f2e3ce66ba35c5420babaef1fe2d9c43a8faab4080b0dbcc26bc64 Cython-0.27.3.tar.gz
+# License files, locally calculated
+sha256 a6cba85bc92e0cff7a450b1d873c0eaa2e9fc96bf472df0247a26bec77bf3ff9 LICENSE.txt
+sha256 e1eb1c49a8508e8173dac30157e4a6439a44ad8846194746c424fbc3fc2b95d7 COPYING.txt
diff --git a/package/python-cython/python-cython.mk b/package/python-cython/python-cython.mk
new file mode 100644
index 0000000000..26fbaa4253
--- /dev/null
+++ b/package/python-cython/python-cython.mk
@@ -0,0 +1,16 @@
+################################################################################
+#
+# cython
+#
+################################################################################
+
+PYTHON_CYTHON_VERSION = 0.27.3
+PYTHON_CYTHON_SOURCE = Cython-$(PYTHON_CYTHON_VERSION).tar.gz
+PYTHON_CYTHON_SITE = https://pypi.python.org/packages/ee/2a/c4d2cdd19c84c32d978d18e9355d1ba9982a383de87d0fcb5928553d37f4
+PYTHON_CYTHON_SETUP_TYPE = setuptools
+PYTHON_CYTHON_LICENSE = Apache-2.0
+PYTHON_CYTHON_LICENSE_FILES = COPYING.txt LICENSE.txt
+
+# Since there's no toolchain or development files on the target, it makes no
+# sense to allow Cython to be installed to the target
+$(eval $(host-python-package))
--
2.15.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH 1/1] python-cython: new package
2017-11-06 20:35 [Buildroot] [PATCH 1/1] python-cython: new package Joseph Kogut
@ 2017-11-25 12:45 ` Thomas Petazzoni
2017-11-25 18:34 ` Joseph Kogut
0 siblings, 1 reply; 4+ messages in thread
From: Thomas Petazzoni @ 2017-11-25 12:45 UTC (permalink / raw)
To: buildroot
Hello,
On Mon, 6 Nov 2017 12:35:39 -0800, Joseph Kogut wrote:
> diff --git a/package/python-cython/Config.in.host b/package/python-cython/Config.in.host
> new file mode 100644
> index 0000000000..69d32d5ab3
> --- /dev/null
> +++ b/package/python-cython/Config.in.host
> @@ -0,0 +1,7 @@
> +config BR2_PACKAGE_HOST_PYTHON_CYTHON
> + bool "host python-cython"
> + help
> + The Cython compiler for writing C extensions for the Python
> + language.
> +
> + http://cython.org/
Could you briefly explain the use-case for Cython, in the context of
Buildroot? How are you using it? To achieve what?
I'm just trying to understand whether it makes sense to have a visible
option in menuconfig for this package (or not).
Thanks!
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH 1/1] python-cython: new package
2017-11-25 12:45 ` Thomas Petazzoni
@ 2017-11-25 18:34 ` Joseph Kogut
2017-11-25 19:37 ` Arnout Vandecappelle
0 siblings, 1 reply; 4+ messages in thread
From: Joseph Kogut @ 2017-11-25 18:34 UTC (permalink / raw)
To: buildroot
Hi Thomas,
On Sat, Nov 25, 2017 at 4:45 AM, Thomas Petazzoni
<thomas.petazzoni@free-electrons.com> wrote:
> Hello,
>
> On Mon, 6 Nov 2017 12:35:39 -0800, Joseph Kogut wrote:
>
>
>> diff --git a/package/python-cython/Config.in.host b/package/python-cython/Config.in.host
>> new file mode 100644
>> index 0000000000..69d32d5ab3
>> --- /dev/null
>> +++ b/package/python-cython/Config.in.host
>> @@ -0,0 +1,7 @@
>> +config BR2_PACKAGE_HOST_PYTHON_CYTHON
>> + bool "host python-cython"
>> + help
>> + The Cython compiler for writing C extensions for the Python
>> + language.
>> +
>> + http://cython.org/
>
> Could you briefly explain the use-case for Cython, in the context of
> Buildroot? How are you using it? To achieve what?
Cython is a dependency of certain Python packages, where it's used in
setup.py to convert Python modules with modified syntax to C, at
which point they're compiled into C extensions. Specifically, I'm
looking to introduce a package for Kivy (https://kivy.org), which
makes use of Cython heavily.
> I'm just trying to understand whether it makes sense to have a visible
> option in menuconfig for this package (or not).
That's a great question, and the answer at this point is that it
probably doesn't. Cython requires a compiler to work, and only the
binaries it generates belong in the target. It might make more sense
for packages that require it to specify it as a dependency in their
makefile.
Would you like me to make that change?
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH 1/1] python-cython: new package
2017-11-25 18:34 ` Joseph Kogut
@ 2017-11-25 19:37 ` Arnout Vandecappelle
0 siblings, 0 replies; 4+ messages in thread
From: Arnout Vandecappelle @ 2017-11-25 19:37 UTC (permalink / raw)
To: buildroot
Hi Joseph,
On 25-11-17 19:34, Joseph Kogut wrote:
> Hi Thomas,
>
> On Sat, Nov 25, 2017 at 4:45 AM, Thomas Petazzoni
> <thomas.petazzoni@free-electrons.com> wrote:
>> Hello,
>>
>> On Mon, 6 Nov 2017 12:35:39 -0800, Joseph Kogut wrote:
>>
>>
>>> diff --git a/package/python-cython/Config.in.host b/package/python-cython/Config.in.host
>>> new file mode 100644
>>> index 0000000000..69d32d5ab3
>>> --- /dev/null
>>> +++ b/package/python-cython/Config.in.host
>>> @@ -0,0 +1,7 @@
>>> +config BR2_PACKAGE_HOST_PYTHON_CYTHON
>>> + bool "host python-cython"
>>> + help
>>> + The Cython compiler for writing C extensions for the Python
>>> + language.
>>> +
>>> + http://cython.org/
>>
>> Could you briefly explain the use-case for Cython, in the context of
>> Buildroot? How are you using it? To achieve what?
>
> Cython is a dependency of certain Python packages, where it's used in
> setup.py to convert Python modules with modified syntax to C, at
> which point they're compiled into C extensions. Specifically, I'm
> looking to introduce a package for Kivy (https://kivy.org), which
> makes use of Cython heavily.
>
>> I'm just trying to understand whether it makes sense to have a visible
>> option in menuconfig for this package (or not).
>
> That's a great question, and the answer at this point is that it
> probably doesn't. Cython requires a compiler to work, and only the
> binaries it generates belong in the target. It might make more sense
> for packages that require it to specify it as a dependency in their
> makefile.
>
> Would you like me to make that change?
Yes please. But then it doesn't make sense to submit the package until there is
another package that actually uses it. So please submit it in a series when you
submit kivy.
When you do, could you make one more small change: in the hash file, you have
'locally computed' and later 'locally calculated'. Use just one of the two
expressions. 'computed' seems to be more popular.
Regards,
Arnout
--
Arnout Vandecappelle arnout at mind be
Senior Embedded Software Architect +32-16-286500
Essensium/Mind http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint: 7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2017-11-25 19:37 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-11-06 20:35 [Buildroot] [PATCH 1/1] python-cython: new package Joseph Kogut
2017-11-25 12:45 ` Thomas Petazzoni
2017-11-25 18:34 ` Joseph Kogut
2017-11-25 19:37 ` Arnout Vandecappelle
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox