diff mbox

[v3,03/11] package/python-simplegeneric: Switch setup type to 'setuptools'

Message ID 20170602235653.4655-4-andrew.smirnov@gmail.com
State Accepted
Headers show

Commit Message

Andrey Smirnov June 2, 2017, 11:56 p.m. UTC
Specifying setup type to be 'distutils' results in this package being
installed as .egg, a zipped file, which inadvertantly makes
'simplegeneric' to be dependent on BR2_PACKAGE_PYTHON*_ZLIB. In order
to avoid that specify setup type to be 'setuptools' which would use
--single-version-externally-managed and install the package as .pyc
and a .egg-info folder.

Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com>
---
 package/python-simplegeneric/python-simplegeneric.mk | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

Comments

Yegor Yefremov June 9, 2017, 7:36 p.m. UTC | #1
On Sat, Jun 3, 2017 at 1:56 AM, Andrey Smirnov <andrew.smirnov@gmail.com> wrote:
> Specifying setup type to be 'distutils' results in this package being
> installed as .egg, a zipped file, which inadvertantly makes
> 'simplegeneric' to be dependent on BR2_PACKAGE_PYTHON*_ZLIB. In order
> to avoid that specify setup type to be 'setuptools' which would use
> --single-version-externally-managed and install the package as .pyc
> and a .egg-info folder.
>
> Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com>

Reviewed-by: Yegor Yefremov <yegorslists@googlemail.com>

> ---
>  package/python-simplegeneric/python-simplegeneric.mk | 8 +++++++-
>  1 file changed, 7 insertions(+), 1 deletion(-)
>
> diff --git a/package/python-simplegeneric/python-simplegeneric.mk b/package/python-simplegeneric/python-simplegeneric.mk
> index 556a478..1d195c3 100644
> --- a/package/python-simplegeneric/python-simplegeneric.mk
> +++ b/package/python-simplegeneric/python-simplegeneric.mk
> @@ -8,7 +8,13 @@ PYTHON_SIMPLEGENERIC_VERSION = 0.8.1
>  PYTHON_SIMPLEGENERIC_SOURCE = simplegeneric-$(PYTHON_SIMPLEGENERIC_VERSION).zip
>  PYTHON_SIMPLEGENERIC_SITE = https://pypi.python.org/packages/3d/57/4d9c9e3ae9a255cd4e1106bb57e24056d3d0709fc01b2e3e345898e49d5b
>  PYTHON_SIMPLEGENERIC_LICENSE = ZPL-2.1
> -PYTHON_SIMPLEGENERIC_SETUP_TYPE = distutils
> +#
> +# Force setup-type to be 'setuptools' in order to force package to be
> +# installed with --single-version-externally-managed. Otherwise we'll
> +# end up wit a .egg file, which is a zip archive, and as such forces
> +# use to have 'zlib' as a runtime dependency
> +#
> +PYTHON_SIMPLEGENERIC_SETUP_TYPE = setuptools
>
>  define PYTHON_SIMPLEGENERIC_EXTRACT_CMDS
>         unzip $(DL_DIR)/$(PYTHON_SIMPLEGENERIC_SOURCE) -d $(@D)
> --
> 2.9.4
>
> _______________________________________________
> buildroot mailing list
> buildroot@busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
Thomas Petazzoni June 11, 2017, 12:50 p.m. UTC | #2
Hello,

On Fri,  2 Jun 2017 16:56:45 -0700, Andrey Smirnov wrote:

> +# Force setup-type to be 'setuptools' in order to force package to be

to force *the* package

> +# installed with --single-version-externally-managed. Otherwise we'll

we'll end up -> we end up

> +# end up wit a .egg file, which is a zip archive, and as such forces
> +# use to have 'zlib' as a runtime dependency

use -> us

Applied after fixing those. Thanks!

Thomas
Peter Korsgaard June 11, 2017, 9:52 p.m. UTC | #3
>>>>> "Thomas" == Thomas Petazzoni <thomas.petazzoni@free-electrons.com> writes:

 > Hello,
 > On Fri,  2 Jun 2017 16:56:45 -0700, Andrey Smirnov wrote:

 >> +# Force setup-type to be 'setuptools' in order to force package to be

 > to force *the* package

 >> +# installed with --single-version-externally-managed. Otherwise we'll

 > we'll end up -> we end up

 >> +# end up wit a .egg file, which is a zip archive, and as such forces
 >> +# use to have 'zlib' as a runtime dependency

 > use -> us

 > Applied after fixing those. Thanks!

Committed to 2017.05.x, thanks.
diff mbox

Patch

diff --git a/package/python-simplegeneric/python-simplegeneric.mk b/package/python-simplegeneric/python-simplegeneric.mk
index 556a478..1d195c3 100644
--- a/package/python-simplegeneric/python-simplegeneric.mk
+++ b/package/python-simplegeneric/python-simplegeneric.mk
@@ -8,7 +8,13 @@  PYTHON_SIMPLEGENERIC_VERSION = 0.8.1
 PYTHON_SIMPLEGENERIC_SOURCE = simplegeneric-$(PYTHON_SIMPLEGENERIC_VERSION).zip
 PYTHON_SIMPLEGENERIC_SITE = https://pypi.python.org/packages/3d/57/4d9c9e3ae9a255cd4e1106bb57e24056d3d0709fc01b2e3e345898e49d5b
 PYTHON_SIMPLEGENERIC_LICENSE = ZPL-2.1
-PYTHON_SIMPLEGENERIC_SETUP_TYPE = distutils
+#
+# Force setup-type to be 'setuptools' in order to force package to be
+# installed with --single-version-externally-managed. Otherwise we'll
+# end up wit a .egg file, which is a zip archive, and as such forces
+# use to have 'zlib' as a runtime dependency
+#
+PYTHON_SIMPLEGENERIC_SETUP_TYPE = setuptools
 
 define PYTHON_SIMPLEGENERIC_EXTRACT_CMDS
 	unzip $(DL_DIR)/$(PYTHON_SIMPLEGENERIC_SOURCE) -d $(@D)