]> www.infradead.org Git - mtd-utils.git/commitdiff
jffs2reader: get rid of linker error
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Mon, 19 Sep 2011 11:25:21 +0000 (14:25 +0300)
committerArtem Bityutskiy <artem.bityutskiy@intel.com>
Wed, 21 Sep 2011 06:35:03 +0000 (09:35 +0300)
There is a linker errors:
undefined reference to `target_endian'

This patch fixes the issue and turns on the jffs2reader build in the Makefile.

Signed-off-by: Alexey Dokuchaev <danfe@nsu.ru>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@intel.com>
Makefile
jffs2reader.c

index 5a0044b805a469038a8137917e24993670f1fca0..f067d86d0047ee9a54c2a7c616d514e5354795b1 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -24,7 +24,7 @@ MTD_BINS = \
        nftldump nftl_format docfdisk \
        rfddump rfdformat \
        serve_image recv_image \
-       sumtool #jffs2reader
+       sumtool jffs2reader
 UBI_BINS = \
        ubiupdatevol ubimkvol ubirmvol ubicrc32 ubinfo ubiattach \
        ubidetach ubinize ubiformat ubirename mtdinfo ubirsvol
index ef9dbe3c68a2cce3e58e211cbcbdcaa3dc5b33d3..b995f197baa1dcf935d7d58d5cba1a425bab7118 100644 (file)
@@ -102,6 +102,8 @@ struct dir {
        char name[256];
 };
 
+int target_endian = __BYTE_ORDER;
+
 void putblock(char *, size_t, size_t *, struct jffs2_raw_inode *);
 struct dir *putdir(struct dir *, struct jffs2_raw_dirent *);
 void printdir(char *o, size_t size, struct dir *d, char *path,