Commit 102a93bd authored by Thomas Petazzoni's avatar Thomas Petazzoni Committed by Peter Korsgaard
Browse files

support: move package/gnuconfig to support/gnuconfig



The CONFIG_UPDATE macro is no longer defined in
package/gnuconfig/gnuconfig.mk, but instead in
package/Makefile.autotools.in. It it also changed a little bit to take
the directory of the package sources as argument, and the AUTOTARGETS
infrastructure is updated to use this macro.

[Peter: drop echo in CONFIG_UPDATE]
Signed-off-by: default avatarThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: default avatarPeter Korsgaard <jacmet@sunsite.dk>
parent 56da3859
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -193,7 +193,7 @@ unexport CFLAGS
unexport CXXFLAGS
unexport GREP_OPTIONS

GNU_HOST_NAME:=$(shell package/gnuconfig/config.guess)
GNU_HOST_NAME:=$(shell support/gnuconfig/config.guess)

#############################################################
#
+18 −5
Original line number Diff line number Diff line
@@ -22,6 +22,22 @@
#
################################################################################


#
# Utility function to upgrade config.sub and config.guess files
#
# argument 1 : directory into which config.guess and config.sub need
# to be updated. Note that config.sub and config.guess are searched
# recursively in this directory.
#
define CONFIG_UPDATE
	for file in config.guess config.sub; do \
		for i in $$(find $(1) -name $$file); do \
			cp support/gnuconfig/$$file $$i; \
		done; \
	done
endef

################################################################################
# AUTOTARGETS_INNER -- defines how the configuration, compilation and
# installation of an autotools package should be done, implements a
@@ -132,11 +148,8 @@ endif
# Hook to update config.sub and config.guess if needed
#
define UPDATE_CONFIG_HOOK
	for file in config.guess config.sub; do \
		for i in $$$$(find $$(@D) -name $$$$file); do \
			cp package/gnuconfig/$$$$file $$$$i; \
		done; \
	done
       @$$(call MESSAGE, "Updating config.sub and config.guess")
       $$(call CONFIG_UPDATE,$$(@D))
endef

$(2)_POST_PATCH_HOOKS += UPDATE_CONFIG_HOOK
+1 −1
Original line number Diff line number Diff line
@@ -70,7 +70,7 @@ $(DL_DIR)/$(CUPS_SOURCE):
$(CUPS_DIR)/.unpacked: $(DL_DIR)/$(CUPS_SOURCE)
	$(CUPS_CAT) $(DL_DIR)/$(CUPS_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
	support/scripts/apply-patches.sh $(CUPS_DIR) package/cups/ \*.patch
	$(CONFIG_UPDATE) $(CUPS_DIR)
	$(call CONFIG_UPDATE,$(CUPS_DIR))
	touch $@

$(CUPS_DIR)/.configured: $(CUPS_DIR)/.unpacked
+1 −2
Original line number Diff line number Diff line
@@ -25,8 +25,7 @@ gettext-source: $(DL_DIR)/$(GETTEXT_SOURCE)
$(GETTEXT_DIR)/.unpacked: $(DL_DIR)/$(GETTEXT_SOURCE)
	$(GETTEXT_CAT) $(DL_DIR)/$(GETTEXT_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
	support/scripts/apply-patches.sh $(GETTEXT_DIR) package/gettext/ gettext\*.patch
	$(CONFIG_UPDATE) $(@D)
	$(CONFIG_UPDATE) $(GETTEXT_DIR)/build-aux
	$(call CONFIG_UPDATE,$(@D))
	touch $@

ifneq ($(BR2_TOOLCHAIN_BUILDROOT),y)

package/gnuconfig/gnuconfig.mk

deleted100644 → 0
+0 −3
Original line number Diff line number Diff line
# See README.buildroot
gnuconfig-source:
CONFIG_UPDATE = cp -f package/gnuconfig/config.sub package/gnuconfig/config.guess
Loading