X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/4841fc240d1f9346ed0a37f1bedb267d33b76645..d4876278a77ed6576073cc6fd81d2ec43eb85733:/netdissect-stdinc.h diff --git a/netdissect-stdinc.h b/netdissect-stdinc.h old mode 100644 new mode 100755 index de277319..c7070f0a --- a/netdissect-stdinc.h +++ b/netdissect-stdinc.h @@ -51,13 +51,11 @@ #include #include #include -#include "bittypes.h" /* in wpcap's Win32/include */ #include #include #include #include #include -#include /* in wpcap's Win32/include */ #ifndef uint8_t #define uint8_t unsigned char @@ -137,6 +135,17 @@ #endif /* _MSC_EXTENSIONS */ +/* + * Suppress definition of intN_t in bittypes.h, as included by + * on Windows. + * (Yes, HAVE_U_INTn_T, as the definition guards are UN*X-oriented, and + * we check for u_intN_t in the UN*X configure script.) + */ +#define HAVE_U_INT8_T +#define HAVE_U_INT16_T +#define HAVE_U_INT32_T +#define HAVE_U_INT64_T + #ifdef _MSC_VER #define stat _stat #define open _open @@ -153,6 +162,10 @@ #define inline __inline #endif +#ifdef AF_INET6 +#define HAVE_OS_IPV6_SUPPORT +#endif + #ifndef INET6_ADDRSTRLEN #define INET6_ADDRSTRLEN 46 #endif @@ -306,6 +319,7 @@ typedef char* caddr_t; * define struct in6_addr so that we can use it for IPv6 addresses. */ #ifndef HAVE_OS_IPV6_SUPPORT +#ifndef AF_INET6 #define AF_INET6 24 struct in6_addr { @@ -316,11 +330,12 @@ struct in6_addr { } __u6_addr; /* 128-bit IP6 address */ }; #endif +#endif #ifndef NI_MAXHOST #define NI_MAXHOST 1025 #endif - + #ifndef INET_ADDRSTRLEN #define INET_ADDRSTRLEN 16 #endif