[U-Boot] [PATCH] Can build with only jffs2 cmdline support
Kyungmin Park
kmpark at infradead.org
Fri Feb 27 09:57:36 CET 2009
Some program such as UBI only used the mtdpart only.
however current jffs2 cmdline has dependent with jffs2 cmd
This patch make a build only jffs2 cmdline without jffs2 cmd dependency.
Signed-off-by: Kyungmin Park <kyungmin.park at samsung.com>
---
diff --git a/common/Makefile b/common/Makefile
index f13cd11..18d76fa 100644
--- a/common/Makefile
+++ b/common/Makefile
@@ -98,6 +98,7 @@ COBJS-$(CONFIG_CMD_IMMAP) += cmd_immap.o
COBJS-$(CONFIG_CMD_IRQ) += cmd_irq.o
COBJS-$(CONFIG_CMD_ITEST) += cmd_itest.o
COBJS-$(CONFIG_CMD_JFFS2) += cmd_jffs2.o
+COBJS-$(CONFIG_JFFS2_CMDLINE) += cmd_jffs2.o
COBJS-$(CONFIG_CMD_LICENSE) += cmd_license.o
COBJS-y += cmd_load.o
COBJS-$(CONFIG_LOGBUFFER) += cmd_log.o
diff --git a/common/cmd_jffs2.c b/common/cmd_jffs2.c
index d0a7cea..3af1bff 100644
--- a/common/cmd_jffs2.c
+++ b/common/cmd_jffs2.c
@@ -2005,6 +2005,7 @@ static struct part_info* jffs2_part_info(struct mtd_device *dev, unsigned int pa
/* U-boot commands */
/***************************************************/
+#ifdef CONFIG_CMD_JFFS2
/**
* Routine implementing fsload u-boot command. This routine tries to load
* a requested file from jffs2/cramfs filesystem on a current partition.
@@ -2144,6 +2145,7 @@ int do_jffs2_fsinfo(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
}
return 1;
}
+#endif /* CONFIG_CMD_JFFS2 */
/* command line only */
#ifdef CONFIG_JFFS2_CMDLINE
@@ -2295,6 +2297,7 @@ int do_jffs2_mtdparts(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
#endif /* #ifdef CONFIG_JFFS2_CMDLINE */
/***************************************************/
+#ifdef CONFIG_CMD_JFFS2
U_BOOT_CMD(
fsload, 3, 0, do_jffs2_fsload,
"load binary file from a filesystem image",
@@ -2314,6 +2317,7 @@ U_BOOT_CMD(
"print information about filesystems",
" - print information about filesystems\n"
);
+#endif
#ifdef CONFIG_JFFS2_CMDLINE
U_BOOT_CMD(
More information about the U-Boot
mailing list