summaryrefslogtreecommitdiff
path: root/source3/wscript
diff options
context:
space:
mode:
authorKai Blin <kai@samba.org>2010-03-21 22:49:25 +0100
committerAndrew Tridgell <tridge@samba.org>2010-04-06 20:27:03 +1000
commitc37f6e649d6e5f8d60e9e5adbbe66455e49f64d5 (patch)
treebb1d1995728948f22707d8a2b88e01b0024d05d7 /source3/wscript
parent565191e39f23f6203412ecee728d15666906ca48 (diff)
downloadsamba-c37f6e649d6e5f8d60e9e5adbbe66455e49f64d5.tar.gz
samba-c37f6e649d6e5f8d60e9e5adbbe66455e49f64d5.tar.bz2
samba-c37f6e649d6e5f8d60e9e5adbbe66455e49f64d5.zip
build: Check for kernel share modes
Diffstat (limited to 'source3/wscript')
-rw-r--r--source3/wscript15
1 files changed, 15 insertions, 0 deletions
diff --git a/source3/wscript b/source3/wscript
index 115adc408d..1f91b1f466 100644
--- a/source3/wscript
+++ b/source3/wscript
@@ -76,6 +76,21 @@ main() {
'HAVE_KERNEL_OPLOCKS_IRIX', headers='sys/types.h fcntl.h',
msg="Checking for IRIX kernel oplock types")
+ # Check for krenel share modes
+ conf.CHECK_CODE('''
+#include <sys/types.h>
+#include <fcntl.h>
+#include <signal.h>
+#include <sys/file.h>
+#ifndef LOCK_MAND
+#define LOCK_MAND 32
+#define LOCK_READ 64
+#endif
+main() {
+ exit(flock(open("/dev/null", O_RDWR), LOCK_MAND|LOCK_READ) != 0);
+}''', 'HAVE_KERNEL_SHARE_MODES', addmain=False, execute=True,
+ msg="Checking for krenel share modes")
+
# Look for CUPS
conf.find_program('cups-config', var='CUPS_CONFIG')
if conf.env.CUPS_CONFIG: