aboutsummaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/spl-build.m423
1 files changed, 23 insertions, 0 deletions
diff --git a/config/spl-build.m4 b/config/spl-build.m4
index 6605b826d..4d02a72ec 100644
--- a/config/spl-build.m4
+++ b/config/spl-build.m4
@@ -44,6 +44,7 @@ AC_DEFUN([SPL_AC_CONFIG_KERNEL], [
SPL_AC_INIT_UTSNAME
SPL_AC_FDTABLE_HEADER
SPL_AC_FILES_FDTABLE
+ SPL_AC_CLEAR_CLOSE_ON_EXEC
SPL_AC_UACCESS_HEADER
SPL_AC_KMALLOC_NODE
SPL_AC_MONOTONIC_CLOCK
@@ -1177,6 +1178,28 @@ AC_DEFUN([SPL_AC_FILES_FDTABLE], [
])
dnl #
+dnl # 3.4.0 API change,
+dnl # check whether '__clear_close_on_exec()' exists
+dnl #
+AC_DEFUN([SPL_AC_CLEAR_CLOSE_ON_EXEC], [
+ AC_MSG_CHECKING([whether __clear_close_on_exec() is available])
+ SPL_LINUX_TRY_COMPILE([
+ #include <linux/fdtable.h>
+ ],[
+ struct fdtable *fdt = NULL;
+ int fd = 0;
+
+ __clear_close_on_exec(fd, fdt);
+ ],[
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_CLEAR_CLOSE_ON_EXEC, 1,
+ [__clear_close_on_exec() is available])
+ ],[
+ AC_MSG_RESULT(no)
+ ])
+])
+
+dnl #
dnl # 2.6.18 API change,
dnl # added linux/uaccess.h
dnl #