aboutsummaryrefslogtreecommitdiff
path: root/git-compat-util.h
diff options
context:
space:
mode:
authorMarkus Duft <mduft@gentoo.org>2010-10-27 10:39:52 +0200
committerJunio C Hamano <gitster@pobox.com>2010-10-28 17:52:22 -0700
commit2844923d62a4c408bd59ddb2caacca4aa7eb86bc (patch)
tree984cbfe179ac14c8f59b62d05f5899c967a3a577 /git-compat-util.h
parent7ebee44167fc25b975f5543472c851ab1840af1b (diff)
downloadgit-2844923d62a4c408bd59ddb2caacca4aa7eb86bc.tar.gz
git-2844923d62a4c408bd59ddb2caacca4aa7eb86bc.tar.xz
add support for the SUA layer (interix; windows)
* add required build options to Makefile. * introduce new NO_INTTYPES_H for systems lacking inttypes; code includes stdint.h instead, if this is set. * introduce new NO_SYS_POLL_H for systems lacking sys/poll.h; code includes poll.h instead, if this is set. * introduce NO_INITGROUPS. initgroups() call is simply omitted. Signed-off-by: Markus Duft <mduft@gentoo.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-compat-util.h')
-rw-r--r--git-compat-util.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/git-compat-util.h b/git-compat-util.h
index 2af8d3edb..625b2e4f1 100644
--- a/git-compat-util.h
+++ b/git-compat-util.h
@@ -106,7 +106,11 @@
#include <utime.h>
#ifndef __MINGW32__
#include <sys/wait.h>
+#ifndef NO_SYS_POLL_H
#include <sys/poll.h>
+#else
+#include <poll.h>
+#endif
#include <sys/socket.h>
#include <sys/ioctl.h>
#include <termios.h>
@@ -118,7 +122,11 @@
#include <arpa/inet.h>
#include <netdb.h>
#include <pwd.h>
+#ifndef NO_INTTYPES_H
#include <inttypes.h>
+#else
+#include <stdint.h>
+#endif
#if defined(__CYGWIN__)
#undef _XOPEN_SOURCE
#include <grp.h>