prot fix
[oweals/gnunet.git] / src / include / platform.h
index 7a31f4fa716799ad502c85c64c0ceaf46624b080..30fa8f9b5988c42eee57173247ae70c12d31c107 100644 (file)
@@ -82,7 +82,9 @@
 #ifndef MINGW
 #include <netdb.h>
 #include <sys/socket.h>
+#include <sys/un.h>
 #include <netinet/in.h>
+#include <netinet/ip.h> /* superset of previous */
 #include <arpa/inet.h>
 #include <netinet/tcp.h>
 #include <pwd.h>
@@ -97,6 +99,7 @@
 #include <string.h>
 #include <stdio.h>
 #include <stdlib.h>
+#include <stdint.h>
 #include <stdarg.h>
 #include <errno.h>
 #include <signal.h>
 #endif
 
 #ifdef FREEBSD
-#ifndef HOST_NAME_MAX
-#define HOST_NAME_MAX MAXHOSTNAMELEN
-#endif
 #define __BYTE_ORDER BYTE_ORDER
 #define __BIG_ENDIAN BIG_ENDIAN
 #endif
 
 #ifdef DARWIN
-#ifndef HOST_NAME_MAX
-#define HOST_NAME_MAX MAXHOSTNAMELEN
-#endif
 #define __BYTE_ORDER BYTE_ORDER
 #define __BIG_ENDIAN BIG_ENDIAN
  /* not available on darwin, override configure */
@@ -218,6 +215,10 @@ long long atoll (const char *nptr);
 #include "langinfo.h"
 #endif
 
+#ifndef SIZE_MAX
+#define SIZE_MAX ((size_t)(-1))
+#endif
+
 #ifndef O_LARGEFILE
 #define O_LARGEFILE 0
 #endif