Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] core/pkg-virtual: fix fallout of host-dependecy no auto-derivation
@ 2016-07-03 10:44 Yann E. MORIN
  2016-07-03 11:20 ` Thomas Petazzoni
  0 siblings, 1 reply; 2+ messages in thread
From: Yann E. MORIN @ 2016-07-03 10:44 UTC (permalink / raw)
  To: buildroot

In 4bdb067 (infra: remove auto derivation of host dependencies), the
dependencies of host packages are not longer inherited from the
dependencies of the corresponding target package.

However, for virtual packages, there is no provider declared for the
host variant, so we end up with no dependency for the  host variants
of virtual packages.

This causes host-luainterpreter to have no provider, and thus breaks the
build of host-luarocks.

To fix that, we use the host variant of the provider of the target
variant of the virtual package to define the provider of the host variant
of the virtual package (re-read it, it's correct!).

Fixes:
    http://autobuild.buildroot.org/results/d8b/d8baf44b1e2f8e0e32c86558fc3e0694235b512a
    http://autobuild.buildroot.org/results/59a/59ac0fe84e5c76a590c698a1483b2a3ae26e1dcf
    http://autobuild.buildroot.org/results/203/2039f24731d8e14cde24c613b487b3db530dd238

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Julien Floret <julien.floret@6wind.com>
---
 package/pkg-virtual.mk | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/package/pkg-virtual.mk b/package/pkg-virtual.mk
index 3fbe0a3..0624177 100644
--- a/package/pkg-virtual.mk
+++ b/package/pkg-virtual.mk
@@ -50,7 +50,13 @@ $(2)_SOURCE =
 $(2)_VERSION = virtual
 
 # Add dependency against the provider
+# For a host package, there is no corresponding BR2_PACKAGE_PROVIDES_HOST_FOO,
+# so we need to compute it from the target variant.
+ifeq ($(4),target)
 $(2)_DEPENDENCIES += $$(call qstrip,$$(BR2_PACKAGE_PROVIDES_$(2)))
+else
+$(2)_DEPENDENCIES += host-$$(call qstrip,$$(BR2_PACKAGE_PROVIDES_$(3)))
+endif
 
 # Call the generic package infrastructure to generate the necessary
 # make targets
-- 
2.7.4

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

end of thread, other threads:[~2016-07-03 11:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-03 10:44 [Buildroot] [PATCH] core/pkg-virtual: fix fallout of host-dependecy no auto-derivation Yann E. MORIN
2016-07-03 11:20 ` Thomas Petazzoni

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