summaryrefslogtreecommitdiff
path: root/source3/configure.in
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2000-06-08 07:40:55 +0000
committerAndrew Tridgell <tridge@samba.org>2000-06-08 07:40:55 +0000
commitbda48b382477f2a6478ebd86b67cb63ac391854e (patch)
tree9ed7aca8ccb05e3dd206bb837c2164301bcfce0d /source3/configure.in
parent6d38ba721ce57a9a574b5f0c24621df3dfcd0738 (diff)
downloadsamba-bda48b382477f2a6478ebd86b67cb63ac391854e.tar.gz
samba-bda48b382477f2a6478ebd86b67cb63ac391854e.tar.bz2
samba-bda48b382477f2a6478ebd86b67cb63ac391854e.zip
- changed HAVE_KERNEL_OPLOCKS to HAVE_KERNEL_OPLOCKS_IRIX
- added autoconf test for HAVE_KERNEL_OPLOCKS_LINUX (This used to be commit 0368f68529a9244663c199068e95d1a1d93152fa)
Diffstat (limited to 'source3/configure.in')
-rw-r--r--source3/configure.in25
1 files changed, 21 insertions, 4 deletions
diff --git a/source3/configure.in b/source3/configure.in
index 742d50da49..2738255b13 100644
--- a/source3/configure.in
+++ b/source3/configure.in
@@ -704,13 +704,30 @@ if test x"$samba_cv_HAVE_UX_UT_SYSLEN" = x"yes"; then
AC_DEFINE(HAVE_UX_UT_SYSLEN)
fi
-AC_CACHE_CHECK([for kernel oplock type definitions],samba_cv_HAVE_KERNEL_OPLOCKS,[
+AC_CACHE_CHECK([for Linux kernel oplocks],samba_cv_HAVE_KERNEL_OPLOCKS_LINUX,[
+AC_TRY_RUN([
+#include <sys/types.h>
+#include <fcntl.h>
+#ifndef F_GETLEASE
+#define F_GETLEASE 13
+#endif
+main() {
+ int fd = open("/dev/null", O_RDONLY);
+ return fcntl(fd, F_GETLEASE, 0) == -1;
+}
+],
+samba_cv_HAVE_KERNEL_OPLOCKS_LINUX=yes,samba_cv_HAVE_KERNEL_OPLOCKS_LINUX=no,samba_cv_HAVE_KERNEL_OPLOCKS_LINUX=cross)])
+if test x"$samba_cv_HAVE_KERNEL_OPLOCKS_LINUX" = x"yes"; then
+ AC_DEFINE(HAVE_KERNEL_OPLOCKS_LINUX)
+fi
+
+AC_CACHE_CHECK([for IRIX kernel oplock type definitions],samba_cv_HAVE_KERNEL_OPLOCKS_IRIX,[
AC_TRY_COMPILE([#include <sys/types.h>
#include <fcntl.h>],
[oplock_stat_t t; t.os_state = OP_REVOKE; t.os_dev = 1; t.os_ino = 1;],
-samba_cv_HAVE_KERNEL_OPLOCKS=yes,samba_cv_HAVE_KERNEL_OPLOCKS=no)])
-if test x"$samba_cv_HAVE_KERNEL_OPLOCKS" = x"yes"; then
- AC_DEFINE(HAVE_KERNEL_OPLOCKS)
+samba_cv_HAVE_KERNEL_OPLOCKS_IRIX=yes,samba_cv_HAVE_KERNEL_OPLOCKS_IRIX=no)])
+if test x"$samba_cv_HAVE_KERNEL_OPLOCKS_IRIX" = x"yes"; then
+ AC_DEFINE(HAVE_KERNEL_OPLOCKS_IRIX)
fi
AC_CACHE_CHECK([for irix specific capabilities],samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES,[