X-Git-Url: http://git.tremily.us/?a=blobdiff_plain;f=git-compat-util.h;h=2fbf1fd8b14a57e065674ffec238406f09b71639;hb=03c82da32e5b1143276b7b13084ec029f0f91561;hp=24b5432462234ee25123cb5aa96222bab0f9e28f;hpb=36d1f3d1313af490a4c7dc963f34a2c9a92556d6;p=git.git diff --git a/git-compat-util.h b/git-compat-util.h index 24b543246..2fbf1fd8b 100644 --- a/git-compat-util.h +++ b/git-compat-util.h @@ -74,7 +74,8 @@ # define _XOPEN_SOURCE 500 # endif #elif !defined(__APPLE__) && !defined(__FreeBSD__) && !defined(__USLC__) && \ - !defined(_M_UNIX) && !defined(__sgi) && !defined(__DragonFly__) + !defined(_M_UNIX) && !defined(__sgi) && !defined(__DragonFly__) && \ + !defined(__TANDEM) #define _XOPEN_SOURCE 600 /* glibc2 and AIX 5.3L need 500, OpenBSD needs 600 for S_ISLNK() */ #define _XOPEN_SOURCE_EXTENDED 1 /* AIX 5.3L needs this */ #endif @@ -98,6 +99,9 @@ #include #include #include +#ifdef __TANDEM /* or HAVE_STRINGS_H or !NO_STRINGS_H? */ +#include /* for strcasecmp() */ +#endif #include #include #include @@ -141,6 +145,17 @@ #else #include #endif +#ifdef NO_INTPTR_T +/* + * On I16LP32, ILP32 and LP64 "long" is the save bet, however + * on LLP86, IL33LLP64 and P64 it needs to be "long long", + * while on IP16 and IP16L32 it is "int" (resp. "short") + * Size needs to match (or exceed) 'sizeof(void *)'. + * We can't take "long long" here as not everybody has it. + */ +typedef long intptr_t; +typedef unsigned long uintptr_t; +#endif #if defined(__CYGWIN__) #undef _XOPEN_SOURCE #include