refresh busybox patches
[openwrt/openwrt.git] / package / busybox / patches / 401-darwin_includes.patch
1 Index: busybox-1.7.2/include/platform.h
2 ===================================================================
3 --- busybox-1.7.2.orig/include/platform.h 2007-10-30 15:34:59.000000000 -0500
4 +++ busybox-1.7.2/include/platform.h 2007-10-30 15:35:04.000000000 -0500
5 @@ -137,9 +137,11 @@
6 # include <netinet/in.h>
7 #endif
8
9 +#ifndef __APPLE__
10 #ifndef __socklen_t_defined
11 typedef int socklen_t;
12 #endif
13 +#endif
14
15 /* ---- Compiler dependent settings ------------------------- */
16 #if (defined __digital__ && defined __unix__)
17 @@ -179,7 +181,7 @@
18 #define HAVE_STDINT_H
19 #else
20 /* Largest integral types. */
21 -#if __BIG_ENDIAN__
22 +#if __BIG_ENDIAN__ && !__APPLE__
23 typedef long intmax_t;
24 typedef unsigned long uintmax_t;
25 #else
26 Index: busybox-1.7.2/include/libbb.h
27 ===================================================================
28 --- busybox-1.7.2.orig/include/libbb.h 2007-10-30 15:34:59.000000000 -0500
29 +++ busybox-1.7.2/include/libbb.h 2007-10-30 15:35:04.000000000 -0500
30 @@ -31,7 +31,9 @@
31 #include <sys/mman.h>
32 #include <sys/socket.h>
33 #include <sys/stat.h>
34 +#ifndef __APPLE__
35 #include <sys/statfs.h>
36 +#endif
37 #include <sys/time.h>
38 #include <sys/types.h>
39 #include <sys/wait.h>