diff mbox series

[v2,2/2] package/python-avro: new package

Message ID 20191212124143.220947-3-titouan.christophe@railnova.eu
State Superseded, archived
Headers show
Series new Avro packages | expand

Commit Message

Titouan Christophe Dec. 12, 2019, 12:41 p.m. UTC
Signed-off-by: Titouan Christophe <titouan.christophe@railnova.eu>
---
 DEVELOPERS                           |  1 +
 package/Config.in                    |  1 +
 package/python-avro/Config.in        | 18 ++++++++++++++++++
 package/python-avro/python-avro.hash |  6 ++++++
 package/python-avro/python-avro.mk   | 14 ++++++++++++++
 5 files changed, 40 insertions(+)
 create mode 100644 package/python-avro/Config.in
 create mode 100644 package/python-avro/python-avro.hash
 create mode 100644 package/python-avro/python-avro.mk

Comments

Gilles Talis Dec. 12, 2019, 8:55 p.m. UTC | #1
Hello Titouan, all

Le jeu. 12 déc. 2019 à 13:41, Titouan Christophe
<titouan.christophe@railnova.eu> a écrit :
>
> Signed-off-by: Titouan Christophe <titouan.christophe@railnova.eu>
> ---
>  DEVELOPERS                           |  1 +
>  package/Config.in                    |  1 +
>  package/python-avro/Config.in        | 18 ++++++++++++++++++
>  package/python-avro/python-avro.hash |  6 ++++++
>  package/python-avro/python-avro.mk   | 14 ++++++++++++++
>  5 files changed, 40 insertions(+)
>  create mode 100644 package/python-avro/Config.in
>  create mode 100644 package/python-avro/python-avro.hash
>  create mode 100644 package/python-avro/python-avro.mk
>
> diff --git a/DEVELOPERS b/DEVELOPERS
> index 639bd21904..ea2ab2f645 100644
> --- a/DEVELOPERS
> +++ b/DEVELOPERS
> @@ -2401,6 +2401,7 @@ F:        package/fbgrab/
>  N:     Titouan Christophe <titouan.christophe@railnova.eu>
>  F:     package/avro-c/
>  F:     package/mosquitto/
> +F:     package/python-avro/
>  F:     package/redis/
>
>  N:     Trent Piepho <tpiepho@impinj.com>
> diff --git a/package/Config.in b/package/Config.in
> index 29eaf043cd..4df31645b3 100644
> --- a/package/Config.in
> +++ b/package/Config.in
> @@ -845,6 +845,7 @@ menu "External python modules"
>         source "package/python-attrs/Config.in"
>         source "package/python-autobahn/Config.in"
>         source "package/python-automat/Config.in"
> +       source "package/python-avro/Config.in"
>         source "package/python-babel/Config.in"
>         source "package/python-backcall/Config.in"
>         source "package/python-backports-abc/Config.in"
> diff --git a/package/python-avro/Config.in b/package/python-avro/Config.in
> new file mode 100644
> index 0000000000..90a921eb3f
> --- /dev/null
> +++ b/package/python-avro/Config.in
> @@ -0,0 +1,18 @@
> +config BR2_PACKAGE_PYTHON_AVRO
> +       bool "python-avro"
> +       depends on BR2_PACKAGE_PYTHON3
> +       help
> +         Select this option to install the Avro Python3 language
> +         bindings, and the `avro` command line tool
> +
> +         Apache Avro is a data serialization system.
> +         Avro provides:
> +         - Rich data structures.
> +         - A compact, fast, binary data format.
> +         - A container file, to store persistent data.
> +         - Remote procedure call (RPC).
> +         - Simple integration with dynamic languages.
> +         - Code generation is not required to read or write data
> +           files nor to use or implement RPC protocols.
> +         - Code generation as an optional optimization,
> +           only worth implementing for statically typed languages.
You miss the link to the upstream package: http://avro.apache.org/

> diff --git a/package/python-avro/python-avro.hash b/package/python-avro/python-avro.hash
> new file mode 100644
> index 0000000000..90ed9f2241
> --- /dev/null
> +++ b/package/python-avro/python-avro.hash
> @@ -0,0 +1,6 @@
> +# From https://www-eu.apache.org/dist/avro/avro-1.9.1/py3/avro-python3-1.9.1.tar.gz.sha512
> +sha512 771ce6e5ca6315f5b9108cb4f5dd9488575cc3433ffdd744f96ce7989763728259c89475319fd9c411ed6b65c996b762548c50a697eb1fba9ab024112ca17daa  avro-python3-1.9.1.tar.gz
> +
> +# License files
> +sha256 c79a7fea0e3cac04cd43f20e7b648e5a0ff8fa5344e644b0ee09ca1162b62747  avro/LICENSE
> +sha256 984731deb198a9bb13b74feb165cb84c24b868602164de40df47451a17085afa  avro/NOTICE
Same here. NOTICE only contains a copyright

> diff --git a/package/python-avro/python-avro.mk b/package/python-avro/python-avro.mk
> new file mode 100644
> index 0000000000..08a25f0c84
> --- /dev/null
> +++ b/package/python-avro/python-avro.mk
> @@ -0,0 +1,14 @@
> +################################################################################
> +#
> +# python-avro
> +#
> +################################################################################
> +
> +PYTHON_AVRO_VERSION = 1.9.1
As mentioned, you could benefit from using the same package version as
avro-c... or not.

> +PYTHON_AVRO_SITE = https://www-eu.apache.org/dist/avro/avro-1.9.1/py3
> +PYTHON_AVRO_SOURCE = avro-python3-$(PYTHON_AVRO_VERSION).tar.gz
> +PYTHON_AVRO_LICENSE = Apache-2.0
> +PYTHON_AVRO_LICENSE_FILES = avro/LICENSE avro/NOTICE
It is only avro/LICENSE

> +PYTHON_AVRO_SETUP_TYPE = setuptools
> +
> +$(eval $(python-package))
> --
> 2.23.0
>
> _______________________________________________
> buildroot mailing list
> buildroot@busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
Thanks
Gilles.
Titouan Christophe Dec. 12, 2019, 11:37 p.m. UTC | #2
Hello,

On 12/12/19 9:55 PM, Gilles Talis wrote:
> Hello Titouan, all
> 
> Le jeu. 12 déc. 2019 à 13:41, Titouan Christophe
> <titouan.christophe@railnova.eu> a écrit :

[snip]

>> diff --git a/package/python-avro/python-avro.mk b/package/python-avro/python-avro.mk
>> new file mode 100644
>> index 0000000000..08a25f0c84
>> --- /dev/null
>> +++ b/package/python-avro/python-avro.mk
>> @@ -0,0 +1,14 @@
>> +################################################################################
>> +#
>> +# python-avro
>> +#
>> +################################################################################
>> +
>> +PYTHON_AVRO_VERSION = 1.9.1
> As mentioned, you could benefit from using the same package version as
> avro-c... or not.

I don't see examples of other pkgs doing this kind of cross-pkg version 
reference, do you have one in mind ? (apart from "plugins" packages, 
like all the QT5 modules; as it was the case in the v1 of this Avro series).

To me, this looks like a style decision. I have a preference for the 
"... or not" option, but maybe the core contributors have a guideline ?

> 
>> +PYTHON_AVRO_SITE = https://www-eu.apache.org/dist/avro/avro-1.9.1/py3
>> +PYTHON_AVRO_SOURCE = avro-python3-$(PYTHON_AVRO_VERSION).tar.gz
>> +PYTHON_AVRO_LICENSE = Apache-2.0
>> +PYTHON_AVRO_LICENSE_FILES = avro/LICENSE avro/NOTICE
> It is only avro/LICENSE
> 
>> +PYTHON_AVRO_SETUP_TYPE = setuptools
>> +
>> +$(eval $(python-package))
>> --
>> 2.23.0
>>
>> _______________________________________________
>> buildroot mailing list
>> buildroot@busybox.net
>> http://lists.busybox.net/mailman/listinfo/buildroot
> Thanks
> Gilles.
> 

All your other comments addressed, I will submit a new version of this 
patch as well.

Regards,

Titouan
Titouan Christophe Dec. 12, 2019, 11:47 p.m. UTC | #3
On 12/13/19 12:37 AM, Titouan Christophe wrote:
> Hello,
> 
> On 12/12/19 9:55 PM, Gilles Talis wrote:
>> Hello Titouan, all
>>
>> Le jeu. 12 déc. 2019 à 13:41, Titouan Christophe
>> <titouan.christophe@railnova.eu> a écrit :
> 
> [snip]
> 
>>> diff --git a/package/python-avro/python-avro.mk 
>>> b/package/python-avro/python-avro.mk
>>> new file mode 100644
>>> index 0000000000..08a25f0c84
>>> --- /dev/null
>>> +++ b/package/python-avro/python-avro.mk
>>> @@ -0,0 +1,14 @@
>>> +################################################################################ 
>>>
>>> +#
>>> +# python-avro
>>> +#
>>> +################################################################################ 
>>>
>>> +
>>> +PYTHON_AVRO_VERSION = 1.9.1
>> As mentioned, you could benefit from using the same package version as
>> avro-c... or not.
> 
> I don't see examples of other pkgs doing this kind of cross-pkg version 
> reference, do you have one in mind ? (apart from "plugins" packages, 
> like all the QT5 modules; as it was the case in the v1 of this Avro 
> series).

Actually, protobuf and python-protobuf do this. Unless this was a 
mistake in the first place, I will do the same in Avro for consistency.

Titouan
diff mbox series

Patch

diff --git a/DEVELOPERS b/DEVELOPERS
index 639bd21904..ea2ab2f645 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -2401,6 +2401,7 @@  F:	package/fbgrab/
 N:	Titouan Christophe <titouan.christophe@railnova.eu>
 F:	package/avro-c/
 F:	package/mosquitto/
+F:	package/python-avro/
 F:	package/redis/
 
 N:	Trent Piepho <tpiepho@impinj.com>
diff --git a/package/Config.in b/package/Config.in
index 29eaf043cd..4df31645b3 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -845,6 +845,7 @@  menu "External python modules"
 	source "package/python-attrs/Config.in"
 	source "package/python-autobahn/Config.in"
 	source "package/python-automat/Config.in"
+	source "package/python-avro/Config.in"
 	source "package/python-babel/Config.in"
 	source "package/python-backcall/Config.in"
 	source "package/python-backports-abc/Config.in"
diff --git a/package/python-avro/Config.in b/package/python-avro/Config.in
new file mode 100644
index 0000000000..90a921eb3f
--- /dev/null
+++ b/package/python-avro/Config.in
@@ -0,0 +1,18 @@ 
+config BR2_PACKAGE_PYTHON_AVRO
+	bool "python-avro"
+	depends on BR2_PACKAGE_PYTHON3
+	help
+	  Select this option to install the Avro Python3 language
+	  bindings, and the `avro` command line tool
+
+	  Apache Avro is a data serialization system.
+	  Avro provides:
+	  - Rich data structures.
+	  - A compact, fast, binary data format.
+	  - A container file, to store persistent data.
+	  - Remote procedure call (RPC).
+	  - Simple integration with dynamic languages.
+	  - Code generation is not required to read or write data
+	    files nor to use or implement RPC protocols.
+	  - Code generation as an optional optimization,
+	    only worth implementing for statically typed languages.
diff --git a/package/python-avro/python-avro.hash b/package/python-avro/python-avro.hash
new file mode 100644
index 0000000000..90ed9f2241
--- /dev/null
+++ b/package/python-avro/python-avro.hash
@@ -0,0 +1,6 @@ 
+# From https://www-eu.apache.org/dist/avro/avro-1.9.1/py3/avro-python3-1.9.1.tar.gz.sha512
+sha512 771ce6e5ca6315f5b9108cb4f5dd9488575cc3433ffdd744f96ce7989763728259c89475319fd9c411ed6b65c996b762548c50a697eb1fba9ab024112ca17daa  avro-python3-1.9.1.tar.gz
+
+# License files
+sha256 c79a7fea0e3cac04cd43f20e7b648e5a0ff8fa5344e644b0ee09ca1162b62747  avro/LICENSE
+sha256 984731deb198a9bb13b74feb165cb84c24b868602164de40df47451a17085afa  avro/NOTICE
diff --git a/package/python-avro/python-avro.mk b/package/python-avro/python-avro.mk
new file mode 100644
index 0000000000..08a25f0c84
--- /dev/null
+++ b/package/python-avro/python-avro.mk
@@ -0,0 +1,14 @@ 
+################################################################################
+#
+# python-avro
+#
+################################################################################
+
+PYTHON_AVRO_VERSION = 1.9.1
+PYTHON_AVRO_SITE = https://www-eu.apache.org/dist/avro/avro-1.9.1/py3
+PYTHON_AVRO_SOURCE = avro-python3-$(PYTHON_AVRO_VERSION).tar.gz
+PYTHON_AVRO_LICENSE = Apache-2.0
+PYTHON_AVRO_LICENSE_FILES = avro/LICENSE avro/NOTICE
+PYTHON_AVRO_SETUP_TYPE = setuptools
+
+$(eval $(python-package))