From 830c308cf98f1d4a1516190425429223355f5805 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Sun, 10 Jan 2016 16:35:24 +0000 Subject: [PATCH] build: ignore the linux package in the sdk only for generating package data, not for dependencies Signed-off-by: Felix Fietkau SVN-Revision: 48171 --- include/scan.mk | 6 +----- include/toplevel.mk | 8 +++++++- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/include/scan.mk b/include/scan.mk index 00cfe31fba8..5af035972f6 100644 --- a/include/scan.mk +++ b/include/scan.mk @@ -26,12 +26,8 @@ define feedname $(if $(patsubst feeds/%,,$(1)),,$(word 2,$(subst /, ,$(1)))) endef -ifdef SDK - IGNORE_PACKAGES = linux -endif - define PackageDir - $(if $(filter $(addprefix %_,$(IGNORE_PACKAGES)),$(1)),,$(TMP_DIR)/.$(SCAN_TARGET): $(TMP_DIR)/info/.$(SCAN_TARGET)-$(1)) + $(TMP_DIR)/.$(SCAN_TARGET): $(TMP_DIR)/info/.$(SCAN_TARGET)-$(1) $(TMP_DIR)/info/.$(SCAN_TARGET)-$(1): $(SCAN_DIR)/$(2)/Makefile $(SCAN_STAMP) $(foreach DEP,$(DEPS_$(SCAN_DIR)/$(2)/Makefile) $(SCAN_DEPS),$(wildcard $(if $(filter /%,$(DEP)),$(DEP),$(SCAN_DIR)/$(2)/$(DEP)))) { \ $$(call progress,Collecting $(SCAN_NAME) info: $(SCAN_DIR)/$(2)) \ diff --git a/include/toplevel.mk b/include/toplevel.mk index 03c5b1f5484..d13a37013c8 100644 --- a/include/toplevel.mk +++ b/include/toplevel.mk @@ -69,6 +69,12 @@ ULIMIT_FIX=_limit=`ulimit -n`; [ "$$_limit" = "unlimited" -o "$$_limit" -ge 1024 prepare-mk: FORCE ; +ifdef SDK + IGNORE_PACKAGES = linux +endif + +_ignore = $(foreach p,$(IGNORE_PACKAGES),--ignore $(p)) + prepare-tmpinfo: FORCE @+$(MAKE) -r -s staging_dir/host/.prereq-build $(PREP_MK) mkdir -p tmp/info @@ -76,7 +82,7 @@ prepare-tmpinfo: FORCE $(_SINGLE)$(NO_TRACE_MAKE) -j1 -r -s -f include/scan.mk SCAN_TARGET="targetinfo" SCAN_DIR="target/linux" SCAN_NAME="target" SCAN_DEPS="profiles/*.mk $(TOPDIR)/include/kernel*.mk $(TOPDIR)/include/target.mk" SCAN_DEPTH=2 SCAN_EXTRA="" SCAN_MAKEOPTS="TARGET_BUILD=1" for type in package target; do \ f=tmp/.$${type}info; t=tmp/.config-$${type}.in; \ - [ "$$t" -nt "$$f" ] || ./scripts/metadata.pl $${type}_config "$$f" > "$$t" || { rm -f "$$t"; echo "Failed to build $$t"; false; break; }; \ + [ "$$t" -nt "$$f" ] || ./scripts/metadata.pl $(_ignore) $${type}_config "$$f" > "$$t" || { rm -f "$$t"; echo "Failed to build $$t"; false; break; }; \ done [ tmp/.config-feeds.in -nt tmp/.packagefeeds ] || ./scripts/feeds feed_config > tmp/.config-feeds.in ./scripts/metadata.pl package_mk tmp/.packageinfo > tmp/.packagedeps || { rm -f tmp/.packagedeps; false; } -- 2.30.2