summaryrefslogtreecommitdiff
path: root/target/imagebuilder
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2016-05-13 16:32:23 +0200
committerFelix Fietkau <nbd@nbd.name>2016-05-13 16:32:36 +0200
commit80f4988da31f7ccc01ad24aa1a4a68af2f6f5563 (patch)
tree4a28adaa4a85f212634a0c605a3ac0920d931331 /target/imagebuilder
parent0d10ada19c1a1bff98e2e9cc79ea1dca0fdcbe1c (diff)
downloadmtk-20170518-80f4988da31f7ccc01ad24aa1a4a68af2f6f5563.zip
mtk-20170518-80f4988da31f7ccc01ad24aa1a4a68af2f6f5563.tar.gz
mtk-20170518-80f4988da31f7ccc01ad24aa1a4a68af2f6f5563.tar.bz2
target/imagebuilder: fix using new device profiles
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'target/imagebuilder')
-rw-r--r--target/imagebuilder/files/Makefile22
1 files changed, 9 insertions, 13 deletions
diff --git a/target/imagebuilder/files/Makefile b/target/imagebuilder/files/Makefile
index 1056a42..e0dc0b9 100644
--- a/target/imagebuilder/files/Makefile
+++ b/target/imagebuilder/files/Makefile
@@ -72,20 +72,16 @@ OPKG:= \
--add-arch all:100 \
--add-arch $(ARCH_PACKAGES):200
-define Profile
- $(eval $(call Profile/Default))
- $(eval $(call Profile/$(1)))
- ifeq ($(USER_PROFILE),)
- USER_PROFILE:=$(1)
- endif
- $(1)_NAME:=$(NAME)
- $(1)_PACKAGES:=$(PACKAGES)
- PROFILE_NAMES += $(1)
- PROFILE_LIST += \
- echo '$(1):'; [ -z '$(NAME)' ] || echo ' $(NAME)'; echo ' Packages: $(PACKAGES)';
-endef
-
include $(INCLUDE_DIR)/target.mk
+-include .profiles.mk
+
+USER_PROFILE ?= $(firstword $(PROFILE_NAMES))
+PROFILE_LIST = $(foreach p,$(PROFILE_NAMES), \
+ echo '$(p):'; $(if $($(p)_NAME),echo ' $($(p)_NAME)'; ) echo ' Packages: $($(p)_PACKAGES)'; \
+)
+
+.profiles.mk: .targetinfo
+ $(SCRIPT_DIR)/metadata.pl profile_mk $< '$(BOARD)$(if $(SUBTARGET),/$(SUBTARGET))' > $@
staging_dir/host/.prereq-build: include/prereq-build.mk
mkdir -p tmp