summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2014-11-18 11:28:20 +0000
committerJeremy Allison <jra@samba.org>2014-12-09 04:12:09 +0100
commit658ffb19826b3cfde323c3e16fde4f713e88ffd8 (patch)
tree9554a682d39f9397901f73a29ded5142338eab20
parenta5a5326152a090e737201612f5e29a7ecc457c85 (diff)
downloadsamba-658ffb19826b3cfde323c3e16fde4f713e88ffd8.tar.gz
samba-658ffb19826b3cfde323c3e16fde4f713e88ffd8.tar.xz
samba-658ffb19826b3cfde323c3e16fde4f713e88ffd8.zip
smbd: Compile notify_inotify only if available
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
-rw-r--r--source3/smbd/notify_inotify.c4
-rwxr-xr-xsource3/wscript_build8
2 files changed, 6 insertions, 6 deletions
diff --git a/source3/smbd/notify_inotify.c b/source3/smbd/notify_inotify.c
index fedf9b522f..944f27a155 100644
--- a/source3/smbd/notify_inotify.c
+++ b/source3/smbd/notify_inotify.c
@@ -26,8 +26,6 @@
#include "smbd/smbd.h"
#include "lib/sys_rw_data.h"
-#ifdef HAVE_INOTIFY
-
#include <sys/inotify.h>
/* glibc < 2.5 headers don't have these defines */
@@ -426,5 +424,3 @@ int inotify_watch(TALLOC_CTX *mem_ctx,
return 0;
}
-
-#endif
diff --git a/source3/wscript_build b/source3/wscript_build
index 51d72e78b6..5128b96bfd 100755
--- a/source3/wscript_build
+++ b/source3/wscript_build
@@ -506,6 +506,11 @@ bld.SAMBA3_SUBSYSTEM('sysquotas',
allow_warnings=True,
deps='samba3-util samba-util')
+NOTIFY_SOURCES=''
+
+if bld.CONFIG_SET("HAVE_INOTIFY"):
+ NOTIFY_SOURCES += ' smbd/notify_inotify.c'
+
bld.SAMBA3_LIBRARY('smbd_base',
source='''
smbd/server_reload.c
@@ -595,9 +600,8 @@ bld.SAMBA3_LIBRARY('smbd_base',
smbd/oplock_irix.c
smbd/oplock_linux.c
smbd/notify.c
- smbd/notify_inotify.c
smbd/notify_internal.c
- smbd/build_options.c''',
+ smbd/build_options.c''' + NOTIFY_SOURCES,
deps='''
talloc
tevent