summaryrefslogtreecommitdiff
path: root/include/platform.h
diff options
context:
space:
mode:
authorMike Frysinger2008-02-07 22:41:33 +0000
committerMike Frysinger2008-02-07 22:41:33 +0000
commit9412ec755543a1ddd5f4b39e1fe5a5dd319fa06c (patch)
tree850e90d64948a6c73dabeb95b903c0d6eb701319 /include/platform.h
parent22876c797cdd848b42f98da7c2ae886cc07ca00d (diff)
downloadbusybox-9412ec755543a1ddd5f4b39e1fe5a5dd319fa06c.zip
busybox-9412ec755543a1ddd5f4b39e1fe5a5dd319fa06c.tar.gz
some more fixes for cross-compiling on an OS X host: apple provides core types so dont redefine them, sys/statfs.h is not available, and only use some newer AF_* defines if they are actually available
Diffstat (limited to 'include/platform.h')
-rw-r--r--include/platform.h11
1 files changed, 6 insertions, 5 deletions
diff --git a/include/platform.h b/include/platform.h
index 050338c..9acba63 100644
--- a/include/platform.h
+++ b/include/platform.h
@@ -137,19 +137,20 @@
/* ---- Networking ------------------------------------------ */
#ifndef __APPLE__
# include <arpa/inet.h>
+# ifndef __socklen_t_defined
+typedef int socklen_t;
+# endif
#else
# include <netinet/in.h>
#endif
-#ifndef __socklen_t_defined
-typedef int socklen_t;
-#endif
-
/* ---- Compiler dependent settings ------------------------- */
#if (defined __digital__ && defined __unix__) || defined __APPLE__
# undef HAVE_MNTENT_H
+# undef HAVE_SYS_STATFS_H
#else
# define HAVE_MNTENT_H 1
+# define HAVE_SYS_STATFS_H 1
#endif /* ___digital__ && __unix__ */
/* linux/loop.h relies on __u64. Make sure we have that as a proper type
@@ -180,7 +181,7 @@ __extension__ typedef unsigned long long __u64;
#define HAVE_FEATURES_H
#include <stdint.h>
#define HAVE_STDINT_H
-#else
+#elif !defined __APPLE__
/* Largest integral types. */
#if __BIG_ENDIAN__
typedef long intmax_t;