Makefile.package.in: Pass non-prefixed name as argument to GENTARGETS_INNER.
PATCH 1/1 Makefile.package.in: Pass non-prefixed name as argument to GENTARGETS_INNER.
Instead of effectively running s/^host-// on the package name, just pass the non-prefixed name to GENTARGETS_INNER. This removes the need to ban packages with names starting with "host-".
--- package/Makefile.package.in | 7 ++++--- 1 files changed, 4 insertions(+), 3 deletions(-)
package/Makefile.package.in +4 -3
@@ -347,6 +347,7 @@ $(BUILD_DIR)/%/.stamp_dircleaned: # for host packages # argument 4 is the package directory prefix # argument 5 is the type (target or host) +# argument 6 is the lowercase package name without the host- prefix. ################################################################################ define GENTARGETS_INNER
@@ -516,7 +517,7 @@ $$($(2)_TARGET_INSTALL_HOST): PKG=$(2) $$($(2)_TARGET_BUILD): PKG=$(2) $$($(2)_TARGET_CONFIGURE): PKG=$(2) $$($(2)_TARGET_PATCH): PKG=$(2) -$$($(2)_TARGET_PATCH): RAWNAME=$(patsubst host-%,%,$(1)) +$$($(2)_TARGET_PATCH): RAWNAME=$(6) $$($(2)_TARGET_EXTRACT): PKG=$(2) $$($(2)_TARGET_SOURCE): PKG=$(2) $$($(2)_TARGET_UNINSTALL): PKG=$(2)
@@ -562,10 +563,10 @@ endef # GENTARGETS_INNER define GENTARGETS ifeq ($(3),host) # In the case of host packages, turn the package name "pkg" into "host-pkg" -$(call GENTARGETS_INNER,$(3)-$(2),$(call UPPERCASE,$(3)-$(2)),$(call UPPERCASE,$(2)),$(1),host) +$(call GENTARGETS_INNER,$(3)-$(2),$(call UPPERCASE,$(3)-$(2)),$(call UPPERCASE,$(2)),$(1),host,$(2)) else # In the case of target packages, keep the package name "pkg" -$(call GENTARGETS_INNER,$(2),$(call UPPERCASE,$(2)),$(call UPPERCASE,$(2)),$(1),target) +$(call GENTARGETS_INNER,$(2),$(call UPPERCASE,$(2)),$(call UPPERCASE,$(2)),$(1),target,$(2)) endif endef
Signature · 1 line
1.7.6
PATCH 1/1 Makefile.package.in: Pass non-prefixed name as argument to GENTARGETS_INNER.
Le Mon, 18 Jul 2011 10:46:07 +0100,
Quotient Remainder <[email protected]> a ?crit :
Quoted 5 lines
Instead of effectively running s/^host-// on the package name, just pass the non-prefixed name to
GENTARGETS_INNER. This removes the need to ban packages with names starting with "host-".Signed-off-by Quotient Remainder <[email protected]>
I have taken this patch in my branch dedicated to package infrastructure improvements, but did the following changes :
* Updated the AUTOTARGETS and CMAKETARGETS infrastructures as well
* Put the new argument in position 2 of GENTARGETS_INNER instead of the last argument. It requires a lot of renaming inside GENTARGETS_INNER, but it is a lot cleaner to have arg 1, lowercase package name with host-, arg 2, lowercase package name without host-, arg 3 uppercase package name with HOST_, arg 4, uppercase package name without HOST_
It will be part of an upcoming pull requests with various improvements to the package infrastructure.
Thanks !
Thomas
Signature · 4 lines
Thomas Petazzoni, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com