summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorĐoàn Trần Công Danh <congdanhqx@gmail.com>2018-11-14 01:10:43 (GMT)
committerJunio C Hamano <gitster@pobox.com>2018-11-14 07:32:24 (GMT)
commit2648ccc231b38206e2dafe9a6cc1ca0978bcef5e (patch)
tree41b4cd2c75ffdec1fd77bf9cf314a8078151ce5d /configure.ac
parentd166e6afe5f257217836ef24a73764eba390c58d (diff)
downloadgit-2648ccc231b38206e2dafe9a6cc1ca0978bcef5e.zip
git-2648ccc231b38206e2dafe9a6cc1ca0978bcef5e.tar.gz
git-2648ccc231b38206e2dafe9a6cc1ca0978bcef5e.tar.bz2
git-compat-util: prefer poll.h to sys/poll.h
POSIX specifies that <poll.h> is the correct header for poll(2) whereas <sys/poll.h> is only needed for some old libc. Let's follow the POSIX way by default. This effectively eliminates musl's warning: warning redirecting incorrect #include <sys/poll.h> to <poll.h> Signed-off-by: Đoàn Trần Công Danh <congdanhqx@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac6
1 files changed, 6 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index e11b797..908e66a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -792,6 +792,12 @@ AC_CHECK_HEADER([sys/select.h],
[NO_SYS_SELECT_H=UnfortunatelyYes])
GIT_CONF_SUBST([NO_SYS_SELECT_H])
#
+# Define NO_POLL_H if you don't have poll.h
+AC_CHECK_HEADER([poll.h],
+[NO_POLL_H=],
+[NO_POLL_H=UnfortunatelyYes])
+GIT_CONF_SUBST([NO_POLL_H])
+#
# Define NO_SYS_POLL_H if you don't have sys/poll.h
AC_CHECK_HEADER([sys/poll.h],
[NO_SYS_POLL_H=],