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 | f5a0a578f8ccf7df7a742bb0fcf16b7161fad393 (patch) | |
tree | 3f3782e219d726a938b2596b8c6ae2d55befb6db /include | |
parent | 6a4f2922f6303a006d66b4bbb79541823b1c12b4 (diff) | |
download | upstream-f5a0a578f8ccf7df7a742bb0fcf16b7161fad393.tar.gz upstream-f5a0a578f8ccf7df7a742bb0fcf16b7161fad393.tar.bz2 upstream-f5a0a578f8ccf7df7a742bb0fcf16b7161fad393.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>
SVN-Revision: 37050
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) |