Fix mkmylofw write_out_padding routine
[openwrt.git] / tools / mtd-utils / patches / 110-portability_fix.patch
1 diff -urN mtd.old/include/asm/types.h mtd.dev/include/asm/types.h
2 --- mtd.old/include/asm/types.h 1970-01-01 01:00:00.000000000 +0100
3 +++ mtd.dev/include/asm/types.h 2006-09-27 16:50:03.000000000 +0200
4 @@ -0,0 +1,3 @@
5 +#ifdef linux
6 +#include_next <asm/types.h>
7 +#endif
8 diff -urN mtd.old/util/mkfs.jffs2.c mtd.dev/util/mkfs.jffs2.c
9 --- mtd.old/util/mkfs.jffs2.c 2004-11-27 00:00:13.000000000 +0100
10 +++ mtd.dev/util/mkfs.jffs2.c 2006-09-27 16:51:56.000000000 +0200
11 @@ -68,6 +68,7 @@
12 #include <zlib.h>
13 #undef crc32
14 #include "crc32.h"
15 +#include <endian.h>
16
17 /* Do not use the wierd XPG version of basename */
18 #undef basename
19 @@ -1032,7 +1033,7 @@
20 case S_IFDIR:
21 if (verbose) {
22 printf("\td %04o %9lu %5d:%-3d %s\n",
23 - e->sb.st_mode & ~S_IFMT, e->sb.st_size,
24 + e->sb.st_mode & ~S_IFMT, (unsigned long)e->sb.st_size,
25 (int) (e->sb.st_uid), (int) (e->sb.st_gid),
26 e->name);
27 }
28 @@ -1041,7 +1042,7 @@
29 case S_IFSOCK:
30 if (verbose) {
31 printf("\ts %04o %9lu %5d:%-3d %s\n",
32 - e->sb.st_mode & ~S_IFMT, e->sb.st_size,
33 + e->sb.st_mode & ~S_IFMT, (unsigned long)e->sb.st_size,
34 (int) e->sb.st_uid, (int) e->sb.st_gid, e->name);
35 }
36 write_pipe(e);
37 @@ -1049,7 +1050,7 @@
38 case S_IFIFO:
39 if (verbose) {
40 printf("\tp %04o %9lu %5d:%-3d %s\n",
41 - e->sb.st_mode & ~S_IFMT, e->sb.st_size,
42 + e->sb.st_mode & ~S_IFMT, (unsigned long)e->sb.st_size,
43 (int) e->sb.st_uid, (int) e->sb.st_gid, e->name);
44 }
45 write_pipe(e);
46 @@ -1075,7 +1076,7 @@
47 case S_IFLNK:
48 if (verbose) {
49 printf("\tl %04o %9lu %5d:%-3d %s -> %s\n",
50 - e->sb.st_mode & ~S_IFMT, e->sb.st_size,
51 + e->sb.st_mode & ~S_IFMT, (unsigned long)e->sb.st_size,
52 (int) e->sb.st_uid, (int) e->sb.st_gid, e->name,
53 e->link);
54 }
55 @@ -1084,7 +1085,7 @@
56 case S_IFREG:
57 if (verbose) {
58 printf("\tf %04o %9lu %5d:%-3d %s\n",
59 - e->sb.st_mode & ~S_IFMT, e->sb.st_size,
60 + e->sb.st_mode & ~S_IFMT, (unsigned long)e->sb.st_size,
61 (int) e->sb.st_uid, (int) e->sb.st_gid, e->name);
62 }
63 write_regular_file(e);
This page took 0.045234 seconds and 5 git commands to generate.