aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ar71xx/image/Makefile
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2012-08-23 11:52:18 +0000
committerGabor Juhos <juhosg@openwrt.org>2012-08-23 11:52:18 +0000
commit2379e6f2a302e90f21a69bd7a101d467a774d3bb (patch)
treee319b7b8837a4550957e211e1e0387dd62800a1e /target/linux/ar71xx/image/Makefile
parent6ebc77af73e48a5397801b19830335784d0d5daf (diff)
downloadupstream-2379e6f2a302e90f21a69bd7a101d467a774d3bb.tar.gz
upstream-2379e6f2a302e90f21a69bd7a101d467a774d3bb.tar.bz2
upstream-2379e6f2a302e90f21a69bd7a101d467a774d3bb.zip
ar71xx: image: add a few helper functions
These functions will be used to simplify the Makefile. SVN-Revision: 33237
Diffstat (limited to 'target/linux/ar71xx/image/Makefile')
-rw-r--r--target/linux/ar71xx/image/Makefile20
1 files changed, 20 insertions, 0 deletions
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
index d885acb168..1f00ba063d 100644
--- a/target/linux/ar71xx/image/Makefile
+++ b/target/linux/ar71xx/image/Makefile
@@ -23,6 +23,26 @@ define factoryname
$(call imgname,$(1),$(2))-factory.bin
endef
+COMMA:=,
+
+define mkcmdline
+$(if $(1),board=$(1) )$(if $(2),console=$(2)$(COMMA)$(3))
+endef
+
+define SingleProfile
+ define Image/Build/Profile/$(3)
+ $$(call Image/Build/Template/$(2)/$$(1),$(1),$(4),$$(call mkcmdline,$(5),$(6),$(7)),$(8),$(9),$(10),$(11),$(12))
+ endef
+endef
+
+define MultiProfile
+ define Image/Build/Profile/$(1)
+ $(foreach p,$(2),
+ $$(call Image/Build/Profile/$p,$$(1))
+ )
+ endef
+endef
+
LOADER_MAKE := $(NO_TRACE_MAKE) -C lzma-loader KDIR=$(KDIR)
KDIR_TMP:=$(KDIR)/tmp