From: Jorge Schrauwen Date: Sun, 3 Apr 2016 09:43:50 +0000 (+0200) Subject: configure: Don't check for inotify on illumos X-Git-Tag: samba-4.2.12~35 X-Git-Url: http://git.samba.org/?p=samba.git;a=commitdiff_plain;h=e3a7138e06e8e3fdd12ee65afa814dcd19e26544 configure: Don't check for inotify on illumos Bug: https://bugzilla.samba.org/show_bug.cgi?id=11816 Reviewed-by: Volker Lendecke Reviewed-by: Jeremy Allison (cherry picked from commit 94f31295b12b20a68d596929ea428eb36f8c0d82) --- diff --git a/source3/wscript b/source3/wscript index a5c83583d16..f7fded880d1 100644 --- a/source3/wscript +++ b/source3/wscript @@ -116,10 +116,13 @@ long ret = splice(0,0,1,0,400,SPLICE_F_MOVE); headers='fcntl.h'): conf.CHECK_DECLS('splice', reverse=True, headers='fcntl.h') - # Check for inotify support - conf.CHECK_HEADERS('sys/inotify.h') - if "HAVE_SYS_INOTIFY_H" in conf.env: - conf.DEFINE('HAVE_INOTIFY', 1) + # Check for inotify support (Skip if we are SunOS) + #NOTE: illumos provides sys/inotify.h but is not an exact match for linux + host_os = sys.platform + if host_os.rfind('sunos') == -1: + conf.CHECK_HEADERS('sys/inotify.h') + if "HAVE_SYS_INOTIFY_H" in conf.env: + conf.DEFINE('HAVE_INOTIFY', 1) # Check for kernel change notify support conf.CHECK_CODE(''' diff --git a/source4/ntvfs/sysdep/wscript_configure b/source4/ntvfs/sysdep/wscript_configure index aa63000499e..274fc08b581 100644 --- a/source4/ntvfs/sysdep/wscript_configure +++ b/source4/ntvfs/sysdep/wscript_configure @@ -1,9 +1,14 @@ #!/usr/bin/env python -conf.CHECK_HEADERS('sys/inotify.h', add_headers=False) +import sys + +# Check for inotify support (Skip if we are SunOS) +#NOTE: illumos provides sys/inotify.h but is not an exact match for linux +host_os = sys.platform +if host_os.rfind('sunos') == -1: + conf.CHECK_HEADERS('sys/inotify.h', add_headers=False) + if (conf.CONFIG_SET('HAVE_SYS_INOTIFY_H')): + conf.DEFINE('HAVE_LINUX_INOTIFY', 1) conf.CHECK_DECLS('F_SETLEASE', headers='linux/fcntl.h', reverse=True) conf.CHECK_DECLS('SA_SIGINFO', headers='signal.h', reverse=True) - -if (conf.CONFIG_SET('HAVE_SYS_INOTIFY_H')): - conf.DEFINE('HAVE_LINUX_INOTIFY', 1)