aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2006-10-19 03:27:24 +0000
committerFelix Fietkau <nbd@openwrt.org>2006-10-19 03:27:24 +0000
commit002476016b414ade238809494cc5b85f59c141ce (patch)
treeff9af4c9c77a5ce5cfd5d9c6b076b8f46fc067b8
parentd2e30add61be46ac839eb5bb7474b78f773b7fd9 (diff)
downloadupstream-002476016b414ade238809494cc5b85f59c141ce.tar.gz
upstream-002476016b414ade238809494cc5b85f59c141ce.tar.bz2
upstream-002476016b414ade238809494cc5b85f59c141ce.zip
make filesystem size selection generic (for ext2)
SVN-Revision: 5221
-rw-r--r--Config.in5
-rw-r--r--include/image.mk5
-rw-r--r--target/image/x86/Config.in5
-rw-r--r--target/image/x86/Makefile2
4 files changed, 11 insertions, 6 deletions
diff --git a/Config.in b/Config.in
index bdd5547d94..f53d71de00 100644
--- a/Config.in
+++ b/Config.in
@@ -95,6 +95,11 @@ comment "Image Options"
source "target/image/*/Config.in"
+ config TARGET_ROOTFS_FSPART
+ int "Filesystem part size (in MB)"
+ depends X86_GRUB_IMAGES || TARGET_ROOTFS_EXT2FS
+ default 16
+
endmenu
source "target/linux/Config.in"
diff --git a/include/image.mk b/include/image.mk
index c738146851..13b722981a 100644
--- a/include/image.mk
+++ b/include/image.mk
@@ -48,9 +48,12 @@ ifneq ($(CONFIG_TARGET_ROOTFS_INITRAMFS),y)
endif
+
ifeq ($(CONFIG_TARGET_ROOTFS_EXT2FS),y)
+ E2SIZE=$(shell echo $$(($(CONFIG_TARGET_ROOTFS_SIZE)*1024)))
+
define Image/mkfs/ext2
- $(STAGING_DIR)/bin/genext2fs -q -b 8192 -I 1500 -d $(BUILD_DIR)/root/ $(KDIR)/root.ext2
+ $(STAGING_DIR)/bin/genext2fs -q -b $(E2SIZE) -I 1500 -d $(BUILD_DIR)/root/ $(KDIR)/root.ext2
$(call Image/Build,ext2)
endef
endif
diff --git a/target/image/x86/Config.in b/target/image/x86/Config.in
index fa61468c96..88d8d37c3b 100644
--- a/target/image/x86/Config.in
+++ b/target/image/x86/Config.in
@@ -14,7 +14,4 @@ config X86_GRUB_KERNELPART
depends X86_GRUB_IMAGES
default 4
-config X86_GRUB_FSPART
- int "Filesystem partition size (in MB)"
- depends X86_GRUB_IMAGES
- default 16
+
diff --git a/target/image/x86/Makefile b/target/image/x86/Makefile
index b836f3ace6..0860245453 100644
--- a/target/image/x86/Makefile
+++ b/target/image/x86/Makefile
@@ -40,7 +40,7 @@ ifeq ($(CONFIG_X86_GRUB_IMAGES),y)
-e 's#@CMDLINE@#$(strip $(call Image/cmdline/$(1)))#g' \
-e 's#@BAUDRATE@#$(CONFIG_X86_GRUB_BAUDRATE)#g' \
./grub/menu.lst > $(KDIR)/root.grub/boot/grub/menu.lst
- PATH="$(STAGING_DIR)/usr/sbin:$(STAGING_DIR)/bin:$(PATH)" ./gen_image.sh $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1).image $(CONFIG_X86_GRUB_KERNELPART) $(KDIR)/root.grub $(CONFIG_X86_GRUB_FSPART) $(KDIR)/root.$(1)
+ PATH="$(STAGING_DIR)/usr/sbin:$(STAGING_DIR)/bin:$(PATH)" ./gen_image.sh $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1).image $(CONFIG_X86_GRUB_KERNELPART) $(KDIR)/root.grub $(CONFIG_TARGET_ROOTFS_FSPART) $(KDIR)/root.$(1)
endef
endif