on Linux force fcntl/mmap based shared memory and on other systems
authorAndrew Tridgell <tridge@samba.org>
Tue, 15 Dec 1998 03:16:24 +0000 (03:16 +0000)
committerAndrew Tridgell <tridge@samba.org>
Tue, 15 Dec 1998 03:16:24 +0000 (03:16 +0000)
force IPC/shmem based shared memory.

source/include/includes.h

index 58c6ee01bdc720fc348e5c837114fecb0018ba8f..824a5bde5db1852644c10f62b5a3ea3ec1e3e9a7 100644 (file)
 #endif
 
 
+/* if we have both SYSV IPC and shared mmap then we need to choose. For most
+   systems it is much faster to use SYSV IPC, but under Linux it is
+   about 5 times faster to use fcntl, so for Linux systems we force
+   fcntl based locking */
+#if (defined(HAVE_SYSV_IPC) && defined(HAVE_SHARED_MMAP))
+# ifdef LINUX
+#  undef HAVE_SYSV_IPC
+# else
+#  undef HAVE_SHARED_MMAP
+# endif
+#endif
+
+
 #include <sys/types.h>
 
 #ifdef TIME_WITH_SYS_TIME