also install required files for HAVE_INCLUDES
[buildroot.git] / package / mtd / mtd.patch
blob40d6865cc8ec91ecae1618437e057e4cf6240702
1 diff -ur mtd-20050122.orig/util/flash_eraseall.c mtd-20050122.orig-patched/util/flash_eraseall.c
2 --- mtd-20050122.orig/util/flash_eraseall.c 2004-12-09 17:00:52.000000000 -0600
3 +++ mtd-20050122.orig-patched/util/flash_eraseall.c 2007-01-13 22:56:51.864233154 -0600
4 @@ -54,7 +54,7 @@
5 static void display_help (void);
6 static void display_version (void);
7 static struct jffs2_unknown_node cleanmarker;
8 -static int target_endian = __BYTE_ORDER;
9 +int target_endian = __BYTE_ORDER;
11 int main (int argc, char *argv[])
13 @@ -134,7 +134,7 @@
14 if (!quiet)
15 printf ("\nSkipping bad block at 0x%08x\n", erase.start);
16 continue;
17 - } else if (ret == -EOPNOTSUPP) {
18 + } else if (errno == EOPNOTSUPP) {
19 fprintf(stderr, "%s: %s: Bad block check not available\n", exe_name, mtd_device);
20 bbtest = 0;
21 } else if (ret < 0) {
22 diff -ur mtd-20050122.orig/util/mkfs.jffs2.c mtd-20050122.orig-patched/util/mkfs.jffs2.c
23 --- mtd-20050122.orig/util/mkfs.jffs2.c 2004-11-26 17:00:13.000000000 -0600
24 +++ mtd-20050122.orig-patched/util/mkfs.jffs2.c 2007-01-13 22:55:53.627687214 -0600
25 @@ -101,7 +101,7 @@
26 static int squash_uids = 0;
27 static int squash_perms = 0;
28 static int fake_times = 0;
29 -static int target_endian = __BYTE_ORDER;
30 +int target_endian = __BYTE_ORDER;
31 static const char *const app_name = "mkfs.jffs2";
32 static const char *const memory_exhausted = "memory exhausted";
34 diff -ur mtd-20050122.orig/util/sumtool.c mtd-20050122.orig-patched/util/sumtool.c
35 --- mtd-20050122.orig/util/sumtool.c 2005-01-05 17:00:16.000000000 -0600
36 +++ mtd-20050122.orig-patched/util/sumtool.c 2007-01-13 22:56:05.528616125 -0600
37 @@ -68,7 +68,7 @@
38 static int cleanmarker_size = sizeof(cleanmarker);
39 static const char *short_options = "o:i:e:hvVblnc:p";
40 static int erase_block_size = 65536;
41 -static int target_endian = __BYTE_ORDER;
42 +int target_endian = __BYTE_ORDER;
43 static int out_fd = -1;
44 static int in_fd = -1;