All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH next] package/pkg-luarocks: use <pkg>_EXTRACT_DEPENDENCIES
@ 2018-11-16 13:53 Thomas Petazzoni
  2018-11-16 15:08 ` Yann E. MORIN
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Thomas Petazzoni @ 2018-11-16 13:53 UTC (permalink / raw)
  To: buildroot

The host luarocks tool is needed when *extracting* luarocks
packages. Since regular dependencies are only available at the
configure step, it caused the "luarocks" program to be available too
late to be used to extract luarocks packages.

To work around this, host-luarocks was manually added as a dependency
of the extract step of luarocks packages. While this worked fine until
now, it breaks badly with per-package folders, because host-luarocks
is not recorded as an extract dependency of luarocks packages, and
therefore is not copied to the per-package host folder, causing a
failure.

In the mean time, the <pkg>_EXTRACT_DEPENDENCIES mechanism was added,
which aims at fixing exactly this problem, so let's use it and
simplify pkg-luarocks.mk.

Cc: Francois Perrad <francois.perrad@gadz.org>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
 package/pkg-luarocks.mk | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/package/pkg-luarocks.mk b/package/pkg-luarocks.mk
index e2b48cfb4c..29c5e66cd1 100644
--- a/package/pkg-luarocks.mk
+++ b/package/pkg-luarocks.mk
@@ -42,7 +42,8 @@ $(2)_SITE		?= $$(call qstrip,$$(BR2_LUAROCKS_MIRROR))
 
 # Since we do not support host-luarocks-package, we know this is
 # a target package, and can just add the required dependencies
-$(2)_DEPENDENCIES	+= host-luarocks luainterpreter
+$(2)_DEPENDENCIES	+= luainterpreter
+$(2)_EXTRACT_DEPENDENCIES += host-luarocks
 
 #
 # Extract step. Extract into a temporary dir and move the relevant part to the
@@ -71,10 +72,6 @@ endif
 # make targets
 $(call inner-generic-package,$(1),$(2),$(3),$(4))
 
-# $(2)_DEPENDENCIES are handled for configure step (too late)
-# but host-luarocks is required to do the extract
-$$($(2)_TARGET_EXTRACT): | host-luarocks
-
 endef
 
 ################################################################################
-- 
2.19.1

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

* [Buildroot] [PATCH next] package/pkg-luarocks: use <pkg>_EXTRACT_DEPENDENCIES
  2018-11-16 13:53 [Buildroot] [PATCH next] package/pkg-luarocks: use <pkg>_EXTRACT_DEPENDENCIES Thomas Petazzoni
@ 2018-11-16 15:08 ` Yann E. MORIN
  2018-11-16 17:41 ` François Perrad
  2018-11-16 19:25 ` Peter Korsgaard
  2 siblings, 0 replies; 4+ messages in thread
From: Yann E. MORIN @ 2018-11-16 15:08 UTC (permalink / raw)
  To: buildroot

Thomas, All,

On 2018-11-16 14:53 +0100, Thomas Petazzoni spake thusly:
> The host luarocks tool is needed when *extracting* luarocks
> packages. Since regular dependencies are only available at the
> configure step, it caused the "luarocks" program to be available too
> late to be used to extract luarocks packages.
> 
> To work around this, host-luarocks was manually added as a dependency
> of the extract step of luarocks packages. While this worked fine until
> now, it breaks badly with per-package folders, because host-luarocks
> is not recorded as an extract dependency of luarocks packages, and
> therefore is not copied to the per-package host folder, causing a
> failure.
> 
> In the mean time, the <pkg>_EXTRACT_DEPENDENCIES mechanism was added,
> which aims at fixing exactly this problem, so let's use it and
> simplify pkg-luarocks.mk.
> 
> Cc: Francois Perrad <francois.perrad@gadz.org>
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>

Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr>

Regards,
Yann E. MORIN.

> ---
>  package/pkg-luarocks.mk | 7 ++-----
>  1 file changed, 2 insertions(+), 5 deletions(-)
> 
> diff --git a/package/pkg-luarocks.mk b/package/pkg-luarocks.mk
> index e2b48cfb4c..29c5e66cd1 100644
> --- a/package/pkg-luarocks.mk
> +++ b/package/pkg-luarocks.mk
> @@ -42,7 +42,8 @@ $(2)_SITE		?= $$(call qstrip,$$(BR2_LUAROCKS_MIRROR))
>  
>  # Since we do not support host-luarocks-package, we know this is
>  # a target package, and can just add the required dependencies
> -$(2)_DEPENDENCIES	+= host-luarocks luainterpreter
> +$(2)_DEPENDENCIES	+= luainterpreter
> +$(2)_EXTRACT_DEPENDENCIES += host-luarocks
>  
>  #
>  # Extract step. Extract into a temporary dir and move the relevant part to the
> @@ -71,10 +72,6 @@ endif
>  # make targets
>  $(call inner-generic-package,$(1),$(2),$(3),$(4))
>  
> -# $(2)_DEPENDENCIES are handled for configure step (too late)
> -# but host-luarocks is required to do the extract
> -$$($(2)_TARGET_EXTRACT): | host-luarocks
> -
>  endef
>  
>  ################################################################################
> -- 
> 2.19.1
> 

-- 
.-----------------.--------------------.------------------.--------------------.
|  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 next] package/pkg-luarocks: use <pkg>_EXTRACT_DEPENDENCIES
  2018-11-16 13:53 [Buildroot] [PATCH next] package/pkg-luarocks: use <pkg>_EXTRACT_DEPENDENCIES Thomas Petazzoni
  2018-11-16 15:08 ` Yann E. MORIN
@ 2018-11-16 17:41 ` François Perrad
  2018-11-16 19:25 ` Peter Korsgaard
  2 siblings, 0 replies; 4+ messages in thread
From: François Perrad @ 2018-11-16 17:41 UTC (permalink / raw)
  To: buildroot

Le ven. 16 nov. 2018 ? 14:53, Thomas Petazzoni <thomas.petazzoni@bootlin.com>
a ?crit :

> The host luarocks tool is needed when *extracting* luarocks
> packages. Since regular dependencies are only available at the
> configure step, it caused the "luarocks" program to be available too
> late to be used to extract luarocks packages.
>
> To work around this, host-luarocks was manually added as a dependency
> of the extract step of luarocks packages. While this worked fine until
> now, it breaks badly with per-package folders, because host-luarocks
> is not recorded as an extract dependency of luarocks packages, and
> therefore is not copied to the per-package host folder, causing a
> failure.
>
> In the mean time, the <pkg>_EXTRACT_DEPENDENCIES mechanism was added,
> which aims at fixing exactly this problem, so let's use it and
> simplify pkg-luarocks.mk.
>
> Cc: Francois Perrad <francois.perrad@gadz.org>
>

Acked-by: Francois Perrad <francois.perrad@gadz.org>


> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> ---
>  package/pkg-luarocks.mk | 7 ++-----
>  1 file changed, 2 insertions(+), 5 deletions(-)
>
> diff --git a/package/pkg-luarocks.mk b/package/pkg-luarocks.mk
> index e2b48cfb4c..29c5e66cd1 100644
> --- a/package/pkg-luarocks.mk
> +++ b/package/pkg-luarocks.mk
> @@ -42,7 +42,8 @@ $(2)_SITE             ?= $$(call
> qstrip,$$(BR2_LUAROCKS_MIRROR))
>
>  # Since we do not support host-luarocks-package, we know this is
>  # a target package, and can just add the required dependencies
> -$(2)_DEPENDENCIES      += host-luarocks luainterpreter
> +$(2)_DEPENDENCIES      += luainterpreter
> +$(2)_EXTRACT_DEPENDENCIES += host-luarocks
>
>  #
>  # Extract step. Extract into a temporary dir and move the relevant part
> to the
> @@ -71,10 +72,6 @@ endif
>  # make targets
>  $(call inner-generic-package,$(1),$(2),$(3),$(4))
>
> -# $(2)_DEPENDENCIES are handled for configure step (too late)
> -# but host-luarocks is required to do the extract
> -$$($(2)_TARGET_EXTRACT): | host-luarocks
> -
>  endef
>
>
>  ################################################################################
> --
> 2.19.1
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20181116/7e8d7a6b/attachment.html>

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

* [Buildroot] [PATCH next] package/pkg-luarocks: use <pkg>_EXTRACT_DEPENDENCIES
  2018-11-16 13:53 [Buildroot] [PATCH next] package/pkg-luarocks: use <pkg>_EXTRACT_DEPENDENCIES Thomas Petazzoni
  2018-11-16 15:08 ` Yann E. MORIN
  2018-11-16 17:41 ` François Perrad
@ 2018-11-16 19:25 ` Peter Korsgaard
  2 siblings, 0 replies; 4+ messages in thread
From: Peter Korsgaard @ 2018-11-16 19:25 UTC (permalink / raw)
  To: buildroot

>>>>> "Thomas" == Thomas Petazzoni <thomas.petazzoni@bootlin.com> writes:

 > The host luarocks tool is needed when *extracting* luarocks
 > packages. Since regular dependencies are only available at the
 > configure step, it caused the "luarocks" program to be available too
 > late to be used to extract luarocks packages.

 > To work around this, host-luarocks was manually added as a dependency
 > of the extract step of luarocks packages. While this worked fine until
 > now, it breaks badly with per-package folders, because host-luarocks
 > is not recorded as an extract dependency of luarocks packages, and
 > therefore is not copied to the per-package host folder, causing a
 > failure.

 > In the mean time, the <pkg>_EXTRACT_DEPENDENCIES mechanism was added,
 > which aims at fixing exactly this problem, so let's use it and
 > simplify pkg-luarocks.mk.

 > Cc: Francois Perrad <francois.perrad@gadz.org>
 > Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>

Committed to next, thanks.

-- 
Bye, Peter Korsgaard

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

end of thread, other threads:[~2018-11-16 19:25 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-16 13:53 [Buildroot] [PATCH next] package/pkg-luarocks: use <pkg>_EXTRACT_DEPENDENCIES Thomas Petazzoni
2018-11-16 15:08 ` Yann E. MORIN
2018-11-16 17:41 ` François Perrad
2018-11-16 19:25 ` Peter Korsgaard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.