From: Harald Welte Date: Wed, 19 Dec 2007 14:09:58 +0100 Subject: [U-Boot-Users] [PATCH] Fix building with CRAMFS but no JFFS2 support Message-ID: <20071219130958.GW29882@prithivi.gnumonks.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi! Fix building with CRAMFS but not JFFS2 support Signed-off-by: Harald Welte Index: u-boot/fs/cramfs/cramfs.c =================================================================== --- u-boot.orig/fs/cramfs/cramfs.c 2007-02-17 11:46:26.000000000 +0100 +++ u-boot/fs/cramfs/cramfs.c 2007-02-17 11:54:36.000000000 +0100 @@ -27,7 +27,7 @@ #include #include -#if defined(CONFIG_CMD_JFFS2) +#if defined(CONFIG_CMD_CRAMFS) #include #include Index: u-boot/common/cmd_jffs2.c =================================================================== --- u-boot.orig/common/cmd_jffs2.c 2007-02-17 11:47:51.000000000 +0100 +++ u-boot/common/cmd_jffs2.c 2007-02-17 14:08:25.000000000 +0100 @@ -170,10 +170,19 @@ 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); -- - Harald Welte http://openmoko.org/ ============================================================================ Software for the world's first truly open Free Software mobile phone ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ U-Boot-Users mailing list U-Boot-Users at lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/u-boot-users