diff options
author | Florian Fainelli <florian@openwrt.org> | 2013-06-27 19:58:35 +0000 |
---|---|---|
committer | Florian Fainelli <florian@openwrt.org> | 2013-06-27 19:58:35 +0000 |
commit | 405fb366b1bca253f97de49ada16a76913588e88 (patch) | |
tree | 880ccaed7ef125b6f5f0d9dd11d6a6b734d9f7fe /include | |
parent | 704e2ed39d4e157d0c24d4dc3a3078cbacc6505c (diff) | |
download | upstream-405fb366b1bca253f97de49ada16a76913588e88.tar.gz upstream-405fb366b1bca253f97de49ada16a76913588e88.tar.bz2 upstream-405fb366b1bca253f97de49ada16a76913588e88.zip |
include/image.mk: do not make initramfs build exclusive
Allow building initramfs along with other types of filesystems.
Signed-off-by: Florian Fainelli <florian@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@37050 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'include')
-rw-r--r-- | include/image.mk | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/include/image.mk b/include/image.mk index 60cde014de..7d63a18232 100644 --- a/include/image.mk +++ b/include/image.mk @@ -67,47 +67,47 @@ define prepare_generic_squashfs $(STAGING_DIR_HOST)/bin/padjffs2 $(1) 4 8 64 128 256 endef - ifneq ($(CONFIG_TARGET_ROOTFS_INITRAMFS),) - - define Image/BuildKernel - cp $(KDIR)/vmlinux.elf $(BIN_DIR)/$(IMG_PREFIX)-vmlinux.elf - $(call Image/Build/Initramfs) + define Image/BuildKernel/Initramfs + cp $(KDIR)/vmlinux-initramfs.elf $(BIN_DIR)/$(IMG_PREFIX)-initramfs-vmlinux.elf + $(call Image/Build/Initramfs) endef - else + define Image/BuildKernel/Initramfs + endef +endif - define Image/mkfs/jffs2/sub +define Image/mkfs/jffs2/sub # FIXME: removing this line will cause strange behaviour in the foreach loop below $(STAGING_DIR_HOST)/bin/mkfs.jffs2 $(3) -e $(patsubst %k,%KiB,$(1)) -o $(KDIR)/root.jffs2-$(2) -d $(TARGET_DIR) -v 2>&1 1>/dev/null | awk '/^.+$$$$/' $(call add_jffs2_mark,$(KDIR)/root.jffs2-$(2)) $(call Image/Build,jffs2-$(2)) - endef +endef - ifneq ($(CONFIG_TARGET_ROOTFS_JFFS2),) +ifneq ($(CONFIG_TARGET_ROOTFS_JFFS2),) define Image/mkfs/jffs2 $(foreach SZ,$(JFFS2_BLOCKSIZE),$(call Image/mkfs/jffs2/sub,$(SZ),$(SZ),$(JFFS2OPS))) endef - endif +endif - ifneq ($(CONFIG_TARGET_ROOTFS_JFFS2_NAND),) +ifneq ($(CONFIG_TARGET_ROOTFS_JFFS2_NAND),) define Image/mkfs/jffs2_nand $(foreach SZ,$(NAND_BLOCKSIZE), $(call Image/mkfs/jffs2/sub, \ $(word 2,$(subst :, ,$(SZ))),nand-$(subst :,-,$(SZ)), \ $(JFFS2OPTS) --no-cleanmarkers --pagesize=$(word 1,$(subst :, ,$(SZ)))) \ ) endef - endif +endif - ifneq ($(CONFIG_TARGET_ROOTFS_SQUASHFS),) +ifneq ($(CONFIG_TARGET_ROOTFS_SQUASHFS),) define Image/mkfs/squashfs @mkdir -p $(TARGET_DIR)/overlay $(STAGING_DIR_HOST)/bin/mksquashfs4 $(TARGET_DIR) $(KDIR)/root.squashfs -nopad -noappend -root-owned -comp $(SQUASHFSCOMP) $(SQUASHFSOPT) -processors $(if $(CONFIG_PKG_BUILD_JOBS),$(CONFIG_PKG_BUILD_JOBS),1) $(call Image/Build,squashfs) endef - endif +endif - ifneq ($(CONFIG_TARGET_ROOTFS_UBIFS),) +ifneq ($(CONFIG_TARGET_ROOTFS_UBIFS),) define Image/mkfs/ubifs $(CP) ./ubinize.cfg $(KDIR) $(STAGING_DIR_HOST)/bin/mkfs.ubifs $(UBIFS_OPTS) -o $(KDIR)/root.ubifs -d $(TARGET_DIR) @@ -116,8 +116,6 @@ else $(STAGING_DIR_HOST)/bin/ubinize $(UBINIZE_OPTS) -o $(KDIR)/root.ubi ubinize.cfg) $(call Image/Build,ubi) endef - endif - endif ifneq ($(CONFIG_TARGET_ROOTFS_CPIOGZ),) @@ -193,6 +191,7 @@ define BuildImage $(call Image/Prepare) $(call Image/mkfs/prepare) $(call Image/BuildKernel) + $(call Image/BuildKernel/Initramfs) $(call Image/mkfs/cpiogz) $(call Image/mkfs/targz) $(call Image/mkfs/ext4) @@ -205,6 +204,7 @@ define BuildImage else install: compile install-targets $(call Image/BuildKernel) + $(call Image/BuildKernel/Initramfs) $(call Image/mkfs/cpiogz) $(call Image/mkfs/targz) $(call Image/mkfs/ext4) |