Code

glossary: Add definitions for dangling and unreachable objects
[git.git] / git-compat-util.h
index 105ac28f9766cb8800fcf6071fd94ed0e3cdf90a..309240bbce15f732597198818a3c67c3e6274fe8 100644 (file)
 #include <netdb.h>
 #include <pwd.h>
 #include <inttypes.h>
+#if defined(__CYGWIN__)
+#undef _XOPEN_SOURCE
+#include <grp.h>
+#define _XOPEN_SOURCE 600
+#else
 #undef _ALL_SOURCE /* AIX 5.3L defines a struct list with _ALL_SOURCE. */
 #include <grp.h>
 #define _ALL_SOURCE 1
+#endif
 
 #ifndef NO_ICONV
 #include <iconv.h>
@@ -139,6 +145,11 @@ extern char *gitstrcasestr(const char *haystack, const char *needle);
 extern size_t gitstrlcpy(char *, const char *, size_t);
 #endif
 
+#ifdef NO_STRTOUMAX
+#define strtoumax gitstrtoumax
+extern uintmax_t gitstrtoumax(const char *, char **, int);
+#endif
+
 extern void release_pack_memory(size_t);
 
 static inline char* xstrdup(const char *str)