summaryrefslogtreecommitdiff
path: root/common/cmd_jffs2.c
diff options
context:
space:
mode:
authorHarald Welte <laforge@openmoko.org>2007-12-19 14:09:58 +0100
committerWolfgang Denk <wd@denx.de>2008-01-09 13:04:37 +0100
commitf540c42d9564854b19ce9bbb70affe172529fe70 (patch)
tree28ab15e346f076280780402b011c2e44daa706c0 /common/cmd_jffs2.c
parent23d0baf967fecdaf1804f045f6339337c5607eec (diff)
downloadu-boot-imx-f540c42d9564854b19ce9bbb70affe172529fe70.zip
u-boot-imx-f540c42d9564854b19ce9bbb70affe172529fe70.tar.gz
u-boot-imx-f540c42d9564854b19ce9bbb70affe172529fe70.tar.bz2
Fix building with CRAMFS but not JFFS2 support
Signed-off-by: Harald Welte <laforge@openmoko.org>
Diffstat (limited to 'common/cmd_jffs2.c')
-rw-r--r--common/cmd_jffs2.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/common/cmd_jffs2.c b/common/cmd_jffs2.c
index efe9eb7..1b67e73 100644
--- a/common/cmd_jffs2.c
+++ b/common/cmd_jffs2.c
@@ -167,10 +167,19 @@ struct list_head devices;
static struct mtd_device *current_dev = NULL;
static u8 current_partnum = 0;
+#if defined(CONFIG_CMD_CRAMFS)
extern int cramfs_check (struct part_info *info);
extern int cramfs_load (char *loadoffset, struct part_info *info, char *filename);
extern int cramfs_ls (struct part_info *info, char *filename);
extern int cramfs_info (struct part_info *info);
+#else
+/* defining empty macros for function names is ugly but avoids ifdef clutter
+ * all over the code */
+#define cramfs_check(x) (0)
+#define cramfs_load(x,y,z) (-1)
+#define cramfs_ls(x,y) (0)
+#define cramfs_info(x) (0)
+#endif
static struct part_info* jffs2_part_info(struct mtd_device *dev, unsigned int part_num);