aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2008-08-05 18:02:54 +0000
committerFelix Fietkau <nbd@openwrt.org>2008-08-05 18:02:54 +0000
commit18b84c0062052df5da7598053b03d7aca3357e69 (patch)
tree83d85e02c8a4dbed4f99d4bbb869a0cda0cd5d90
parent6ab24d91d299bc19da078014287adc204fce8697 (diff)
downloadupstream-18b84c0062052df5da7598053b03d7aca3357e69.tar.gz
upstream-18b84c0062052df5da7598053b03d7aca3357e69.tar.bz2
upstream-18b84c0062052df5da7598053b03d7aca3357e69.zip
replace config.guess and config.sub properly, even if they are in a subdirectory
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@12148 3c298f89-4303-0410-b956-a3cf2f4a3e73
-rw-r--r--include/package-defaults.mk5
1 files changed, 4 insertions, 1 deletions
diff --git a/include/package-defaults.mk b/include/package-defaults.mk
index d72e02b1e0..fd50cb4d81 100644
--- a/include/package-defaults.mk
+++ b/include/package-defaults.mk
@@ -76,10 +76,13 @@ CONFIGURE_VARS = \
CONFIGURE_PATH = .
CONFIGURE_CMD = ./configure
+replace_script=$(FIND) $(1) -name $(2) | $(XARGS) -n1 cp $(SCRIPT_DIR)/$(2);
+
define Build/Configure/Default
(cd $(PKG_BUILD_DIR)/$(CONFIGURE_PATH)/$(strip $(3)); \
if [ -x $(CONFIGURE_CMD) ]; then \
- $(CP) $(SCRIPT_DIR)/config.{guess,sub} $(PKG_BUILD_DIR)/$(3)/ && \
+ $(call replace_script,$(PKG_BUILD_DIR)/$(3),config.guess) \
+ $(call replace_script,$(PKG_BUILD_DIR)/$(3),config.sub) \
$(CONFIGURE_VARS) \
$(2) \
$(CONFIGURE_CMD) \