Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] package/python-setuptools: add missing dependency on host-python-wheel
@ 2023-06-26 20:29 Romain Naour
  2023-06-27  5:55 ` Yann E. MORIN
  2023-07-03 18:29 ` Arnout Vandecappelle via buildroot
  0 siblings, 2 replies; 4+ messages in thread
From: Romain Naour @ 2023-06-26 20:29 UTC (permalink / raw)
  To: buildroot; +Cc: Romain Naour, James Hilliard

While migrating to pep517 build backend the host-python-wheel
dependency has been added to host-python-setuptools but
not to python-setuptools.

Fixes:
https://gitlab.com/buildroot.org/buildroot/-/jobs/4537951715

Signed-off-by: Romain Naour <romain.naour@gmail.com>
Cc: James Hilliard <james.hilliard1@gmail.com>
---
 package/python-setuptools/python-setuptools.mk | 1 +
 1 file changed, 1 insertion(+)

diff --git a/package/python-setuptools/python-setuptools.mk b/package/python-setuptools/python-setuptools.mk
index d957930455..39ead10f55 100644
--- a/package/python-setuptools/python-setuptools.mk
+++ b/package/python-setuptools/python-setuptools.mk
@@ -12,6 +12,7 @@ PYTHON_SETUPTOOLS_LICENSE_FILES = LICENSE
 PYTHON_SETUPTOOLS_CPE_ID_VENDOR = python
 PYTHON_SETUPTOOLS_CPE_ID_PRODUCT = setuptools
 PYTHON_SETUPTOOLS_SETUP_TYPE = pep517
+PYTHON_SETUPTOOLS_DEPENDENCIES = host-python-wheel
 HOST_PYTHON_SETUPTOOLS_DEPENDENCIES = host-python-wheel
 
 $(eval $(python-package))
-- 
2.41.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [Buildroot] [PATCH] package/python-setuptools: add missing dependency on host-python-wheel
  2023-06-26 20:29 [Buildroot] [PATCH] package/python-setuptools: add missing dependency on host-python-wheel Romain Naour
@ 2023-06-27  5:55 ` Yann E. MORIN
  2023-06-27 18:56   ` James Hilliard
  2023-07-03 18:29 ` Arnout Vandecappelle via buildroot
  1 sibling, 1 reply; 4+ messages in thread
From: Yann E. MORIN @ 2023-06-27  5:55 UTC (permalink / raw)
  To: Romain Naour; +Cc: James Hilliard, buildroot

James, All,

On 2023-06-26 22:29 +0200, Romain Naour spake thusly:
> While migrating to pep517 build backend the host-python-wheel
> dependency has been added to host-python-setuptools but
> not to python-setuptools.
> 
> Fixes:
> https://gitlab.com/buildroot.org/buildroot/-/jobs/4537951715
> 
> Signed-off-by: Romain Naour <romain.naour@gmail.com>
> Cc: James Hilliard <james.hilliard1@gmail.com>
> ---
>  package/python-setuptools/python-setuptools.mk | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/package/python-setuptools/python-setuptools.mk b/package/python-setuptools/python-setuptools.mk
> index d957930455..39ead10f55 100644
> --- a/package/python-setuptools/python-setuptools.mk
> +++ b/package/python-setuptools/python-setuptools.mk
> @@ -12,6 +12,7 @@ PYTHON_SETUPTOOLS_LICENSE_FILES = LICENSE
>  PYTHON_SETUPTOOLS_CPE_ID_VENDOR = python
>  PYTHON_SETUPTOOLS_CPE_ID_PRODUCT = setuptools
>  PYTHON_SETUPTOOLS_SETUP_TYPE = pep517
> +PYTHON_SETUPTOOLS_DEPENDENCIES = host-python-wheel
>  HOST_PYTHON_SETUPTOOLS_DEPENDENCIES = host-python-wheel

Should this not be done in the python package infra instead?

I.e. if host-python-wheel is required by the pep517 build backend, then
all packages that are pep517 will need wheel, so it should be done by
the infra rather than by each individual package...

Of course, by the virtue of being a dependency of python-setuptools, it
becomes a dependency of all python-packages that already depends on
{host-,}python-setuptools, so it technically works, even with PPD.
Nonetheless, it is semantically incorrect.

Or did I miss something?

Regards,
Yann E. MORIN.

>  $(eval $(python-package))
> -- 
> 2.41.0
> 
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Buildroot] [PATCH] package/python-setuptools: add missing dependency on host-python-wheel
  2023-06-27  5:55 ` Yann E. MORIN
@ 2023-06-27 18:56   ` James Hilliard
  0 siblings, 0 replies; 4+ messages in thread
From: James Hilliard @ 2023-06-27 18:56 UTC (permalink / raw)
  To: Yann E. MORIN; +Cc: Romain Naour, buildroot

On Mon, Jun 26, 2023 at 11:55 PM Yann E. MORIN <yann.morin.1998@free.fr> wrote:
>
> James, All,
>
> On 2023-06-26 22:29 +0200, Romain Naour spake thusly:
> > While migrating to pep517 build backend the host-python-wheel
> > dependency has been added to host-python-setuptools but
> > not to python-setuptools.
> >
> > Fixes:
> > https://gitlab.com/buildroot.org/buildroot/-/jobs/4537951715
> >
> > Signed-off-by: Romain Naour <romain.naour@gmail.com>
> > Cc: James Hilliard <james.hilliard1@gmail.com>
> > ---
> >  package/python-setuptools/python-setuptools.mk | 1 +
> >  1 file changed, 1 insertion(+)
> >
> > diff --git a/package/python-setuptools/python-setuptools.mk b/package/python-setuptools/python-setuptools.mk
> > index d957930455..39ead10f55 100644
> > --- a/package/python-setuptools/python-setuptools.mk
> > +++ b/package/python-setuptools/python-setuptools.mk
> > @@ -12,6 +12,7 @@ PYTHON_SETUPTOOLS_LICENSE_FILES = LICENSE
> >  PYTHON_SETUPTOOLS_CPE_ID_VENDOR = python
> >  PYTHON_SETUPTOOLS_CPE_ID_PRODUCT = setuptools
> >  PYTHON_SETUPTOOLS_SETUP_TYPE = pep517
> > +PYTHON_SETUPTOOLS_DEPENDENCIES = host-python-wheel
> >  HOST_PYTHON_SETUPTOOLS_DEPENDENCIES = host-python-wheel
>
> Should this not be done in the python package infra instead?
>
> I.e. if host-python-wheel is required by the pep517 build backend, then
> all packages that are pep517 will need wheel, so it should be done by
> the infra rather than by each individual package...

So host-python-wheel is not required by the pep517 build frontend, only the
setuptools pep517 build backend, it's not needed for flit and non-setuptools
based pep517 build backends.

>
> Of course, by the virtue of being a dependency of python-setuptools, it
> becomes a dependency of all python-packages that already depends on
> {host-,}python-setuptools, so it technically works, even with PPD.
> Nonetheless, it is semantically incorrect.

So setuptools is no longer required in the dependency tree for any
non-setuptools based packages.

See my patch switching setuptools over to the pep517 build frontend:
https://patchwork.ozlabs.org/project/buildroot/patch/20230626181531.2312002-5-james.hilliard1@gmail.com/

>
> Or did I miss something?
>
> Regards,
> Yann E. MORIN.
>
> >  $(eval $(python-package))
> > --
> > 2.41.0
> >
> > _______________________________________________
> > buildroot mailing list
> > buildroot@buildroot.org
> > https://lists.buildroot.org/mailman/listinfo/buildroot
>
> --
> .-----------------.--------------------.------------------.--------------------.
> |  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
> | +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
> | +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
> | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
> '------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Buildroot] [PATCH] package/python-setuptools: add missing dependency on host-python-wheel
  2023-06-26 20:29 [Buildroot] [PATCH] package/python-setuptools: add missing dependency on host-python-wheel Romain Naour
  2023-06-27  5:55 ` Yann E. MORIN
@ 2023-07-03 18:29 ` Arnout Vandecappelle via buildroot
  1 sibling, 0 replies; 4+ messages in thread
From: Arnout Vandecappelle via buildroot @ 2023-07-03 18:29 UTC (permalink / raw)
  To: Romain Naour, buildroot; +Cc: James Hilliard, Yann E. MORIN



On 26/06/2023 22:29, Romain Naour wrote:
> While migrating to pep517 build backend the host-python-wheel
> dependency has been added to host-python-setuptools but
> not to python-setuptools.

  What is really going on here is that setuptools' setup.py checks at build time 
if the wheel dependency is present. Since it uses host-python to check that, we 
need host-python-wheel as a build dependency. I extended the commit message to 
explain this better.

  However, this implies that target python-wheel should also be present at 
runtime. The Z3 in the fixes line doesn't trigger the wheel dependency, but in 
general it should be there. I've therefore also added a runtime dependency in 
the Config.in.

  I think we'll see more of these issues with PEP517 setup types, because PEP517 
tools will generally check dependencies at build time, but they use the host 
directory for that. So I do think that we should find a more generic solution 
for this.

  For now, though, I've just applied this to master, thanks.

  Regards,
  Arnout

> 
> Fixes:
> https://gitlab.com/buildroot.org/buildroot/-/jobs/4537951715
> 
> Signed-off-by: Romain Naour <romain.naour@gmail.com>
> Cc: James Hilliard <james.hilliard1@gmail.com>
> ---
>   package/python-setuptools/python-setuptools.mk | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/package/python-setuptools/python-setuptools.mk b/package/python-setuptools/python-setuptools.mk
> index d957930455..39ead10f55 100644
> --- a/package/python-setuptools/python-setuptools.mk
> +++ b/package/python-setuptools/python-setuptools.mk
> @@ -12,6 +12,7 @@ PYTHON_SETUPTOOLS_LICENSE_FILES = LICENSE
>   PYTHON_SETUPTOOLS_CPE_ID_VENDOR = python
>   PYTHON_SETUPTOOLS_CPE_ID_PRODUCT = setuptools
>   PYTHON_SETUPTOOLS_SETUP_TYPE = pep517
> +PYTHON_SETUPTOOLS_DEPENDENCIES = host-python-wheel
>   HOST_PYTHON_SETUPTOOLS_DEPENDENCIES = host-python-wheel
>   
>   $(eval $(python-package))
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-07-03 18:29 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-06-26 20:29 [Buildroot] [PATCH] package/python-setuptools: add missing dependency on host-python-wheel Romain Naour
2023-06-27  5:55 ` Yann E. MORIN
2023-06-27 18:56   ` James Hilliard
2023-07-03 18:29 ` Arnout Vandecappelle via buildroot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox