summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorRyan Lortie <desrt@desrt.ca>2014-02-13 18:26:07 -0500
committerRyan Lortie <desrt@desrt.ca>2014-02-14 10:42:40 -0500
commit450e7b1036fc95d41d6cb72d48824cd8b438037c (patch)
treef7711de77c074ea01364e40603eb01c524a852c3 /configure.ac
parentdb83b8ac4ce70c31398121f0bde9ac87d4f42c58 (diff)
configure.ac: tweak inotify check
Our check for inotify_init1() being defined is broken. We happily declare that inotify is supported, even if the check fails. This was originally intended to check for inotify_init1 in the libc so that we could fall back to inotify_init if it was not yet defined. FreeBSD has a libinotify that emulates the inotify API via kqueue. It installs a <sys/inotify.h> header and requires linking to -linotify. We don't want to falsely detect working inotify in this case. Treat the lack of inotify_init1() in the libc as a lack of inotify support. This requires only a new libc -- we still support old kernels: in the case that inotify1_init() fails, we fall back to inotify_init(). https://bugzilla.gnome.org/show_bug.cgi?id=724330
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac3
1 files changed, 1 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index 1c400ad9c..c38cd3598 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1665,8 +1665,7 @@ dnl *****************************
inotify_support=no
AC_CHECK_HEADERS([sys/inotify.h],
[
- inotify_support=yes
- AC_CHECK_FUNCS(inotify_init1)
+ AC_CHECK_FUNCS(inotify_init1, [inotify_support=yes], [inotify_support=no])
])
AM_CONDITIONAL(HAVE_INOTIFY, [test "$inotify_support" = "yes"])