summaryrefslogtreecommitdiffstats
path: root/include/target.mk
diff options
context:
space:
mode:
authorblogic <blogic@3c298f89-4303-0410-b956-a3cf2f4a3e73>2011-07-03 17:38:23 +0000
committerblogic <blogic@3c298f89-4303-0410-b956-a3cf2f4a3e73>2011-07-03 17:38:23 +0000
commitb75766abf444b1257f548cc06a6a04314245e30f (patch)
tree03048c35564216a6898a63efbea5b86d3d9ef1bc /include/target.mk
parentdde03ff97ac5e14bec7c35ca73c868efd9ace598 (diff)
automatic subtarget enumaration
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@27407 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'include/target.mk')
-rw-r--r--include/target.mk9
1 files changed, 6 insertions, 3 deletions
diff --git a/include/target.mk b/include/target.mk
index 676b98327..cfd7c9f3c 100644
--- a/include/target.mk
+++ b/include/target.mk
@@ -17,9 +17,6 @@ DEFAULT_PACKAGES:=base-files libc libgcc busybox dropbear mtd uci opkg hotplug2
DEFAULT_PACKAGES.router:=dnsmasq iptables ppp ppp-mod-pppoe kmod-ipt-nathelper firewall
DEFAULT_PACKAGES.bootloader:=
-# Add device specific packages
-DEFAULT_PACKAGES += $(DEFAULT_PACKAGES.$(DEVICE_TYPE))
-
ifneq ($(DUMP),)
all: dumpinfo
endif
@@ -30,6 +27,9 @@ ifeq ($(DUMP),)
SUBTARGET:=$(strip $(foreach subdir,$(patsubst $(PLATFORM_DIR)/%/target.mk,%,$(wildcard $(PLATFORM_DIR)/*/target.mk)),$(if $(CONFIG_TARGET_$(call target_conf,$(BOARD)_$(subdir))),$(subdir))))
else
PLATFORM_DIR:=${CURDIR}
+ ifeq ($(SUBTARGETS),)
+ SUBTARGETS:=$(strip $(patsubst $(PLATFORM_DIR)/%/target.mk,%,$(wildcard $(PLATFORM_DIR)/*/target.mk)))
+ endif
endif
TARGETID:=$(BOARD)$(if $(SUBTARGET),/$(SUBTARGET))
@@ -48,6 +48,9 @@ else
endif
endif
+# Add device specific packages (here below to allow device type set from subtarget)
+DEFAULT_PACKAGES += $(DEFAULT_PACKAGES.$(DEVICE_TYPE))
+
define Profile/Default
NAME:=
PACKAGES:=