diff options
Diffstat (limited to 'config')
-rw-r--r-- | config/user-makedev.m4 | 39 | ||||
-rw-r--r-- | config/user.m4 | 2 |
2 files changed, 41 insertions, 0 deletions
diff --git a/config/user-makedev.m4 b/config/user-makedev.m4 new file mode 100644 index 000000000..4383681a8 --- /dev/null +++ b/config/user-makedev.m4 @@ -0,0 +1,39 @@ +dnl # +dnl # glibc 2.25 +dnl # +AC_DEFUN([ZFS_AC_CONFIG_USER_MAKEDEV_IN_SYSMACROS], [ + AC_MSG_CHECKING([makedev() is declared in sys/sysmacros.h]) + AC_TRY_COMPILE( + [ + #include <sys/sysmacros.h> + ],[ + int k; + k = makedev(0,0); + ],[ + AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_MAKEDEV_IN_SYSMACROS, 1, + [makedev() is declared in sys/sysmacros.h]) + ],[ + AC_MSG_RESULT(no) + ]) +]) + +dnl # +dnl # glibc X < Y < 2.25 +dnl # +AC_DEFUN([ZFS_AC_CONFIG_USER_MAKEDEV_IN_MKDEV], [ + AC_MSG_CHECKING([makedev() is declared in sys/mkdev.h]) + AC_TRY_COMPILE( + [ + #include <sys/mkdev.h> + ],[ + int k; + k = makedev(0,0); + ],[ + AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_MAKEDEV_IN_MKDEV, 1, + [makedev() is declared in sys/mkdev.h]) + ],[ + AC_MSG_RESULT(no) + ]) +]) diff --git a/config/user.m4 b/config/user.m4 index f70ab635f..0e3430757 100644 --- a/config/user.m4 +++ b/config/user.m4 @@ -15,6 +15,8 @@ AC_DEFUN([ZFS_AC_CONFIG_USER], [ ZFS_AC_CONFIG_USER_LIBUDEV ZFS_AC_CONFIG_USER_FRAME_LARGER_THAN ZFS_AC_CONFIG_USER_RUNSTATEDIR + ZFS_AC_CONFIG_USER_MAKEDEV_IN_SYSMACROS + ZFS_AC_CONFIG_USER_MAKEDEV_IN_MKDEV ZFS_AC_CONFIG_USER_COMMANDS ZFS_AC_TEST_FRAMEWORK |