From: Felix Fietkau Date: Wed, 11 May 2016 18:13:58 +0000 (+0200) Subject: build: avoid including profiles/*.mk X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=4a31037a34167a41705de319cdf989a63519debb;p=openwrt%2Fstaging%2F981213.git build: avoid including profiles/*.mk Generate the active profile name in menuconfig context Signed-off-by: Felix Fietkau --- diff --git a/include/target.mk b/include/target.mk index f4342bdbb5..868fe6b375 100644 --- a/include/target.mk +++ b/include/target.mk @@ -84,9 +84,6 @@ define Profile echo "$$$$$$$$$(call shvar,Profile/$(1)/Description)"; \ echo "@@"; \ echo; - ifeq ($(CONFIG_TARGET_$(call target_conf,$(BOARD)_$(if $(SUBTARGET),$(SUBTARGET)_))$(1)),y) - PROFILE=$(1) - endif endef endif @@ -101,10 +98,10 @@ else endef endif +PROFILE:=$(call qstrip,$(CONFIG_TARGET_PROFILE)) + ifeq ($(TARGET_BUILD),1) - $(eval $(call IncludeProfiles)) -else - ifeq ($(DUMP),) + ifneq ($(DUMP),) $(eval $(call IncludeProfiles)) endif endif diff --git a/scripts/metadata.pl b/scripts/metadata.pl index f5afb1e47b..260d06d712 100755 --- a/scripts/metadata.pl +++ b/scripts/metadata.pl @@ -337,6 +337,18 @@ EOF } } print <{profiles}; + foreach my $profile (@$profiles) { + print "\tdefault \"$profile->{id}\" if TARGET_$target->{conf}_$profile->{id}\n"; + } + } + + print <