Merge commit 'refs/top-bases/linux-have-sysevent' into linux-have-sysevent
This commit is contained in:
commit
cf3c0c4bdc
|
@ -0,0 +1,24 @@
|
|||
dnl #
|
||||
dnl # 2.6.x API change
|
||||
dnl # bio_end_io_t uses 2 args (size was dropped from prototype)
|
||||
dnl #
|
||||
AC_DEFUN([ZFS_AC_CONFIG_KERNEL_BIO_ARGS],
|
||||
[AC_MSG_CHECKING([whether bio_end_io_t wants 2 args])
|
||||
tmp_flags="$EXTRA_KCFLAGS"
|
||||
EXTRA_KCFLAGS="-Werror"
|
||||
ZFS_LINUX_TRY_COMPILE([
|
||||
#include <linux/bio.h>
|
||||
],[
|
||||
void (*wanted_end_io)(struct bio *, int) = NULL;
|
||||
bio_end_io_t *local_end_io;
|
||||
|
||||
local_end_io = wanted_end_io;
|
||||
],[
|
||||
AC_MSG_RESULT(yes)
|
||||
AC_DEFINE(HAVE_2ARGS_BIO_END_IO_T, 1,
|
||||
[bio_end_io_t wants 2 args])
|
||||
],[
|
||||
AC_MSG_RESULT(no)
|
||||
])
|
||||
EXTRA_KCFLAGS="$tmp_flags"
|
||||
])
|
|
@ -37,4 +37,6 @@ AC_DEFUN([ZFS_AC_CONFIG_KERNEL], [
|
|||
AC_SUBST(KERNELMAKE_PARAMS)
|
||||
AC_SUBST(KERNELCPPFLAGS)
|
||||
AC_SUBST(HOSTCFLAGS)
|
||||
|
||||
ZFS_AC_CONFIG_KERNEL_BIO_ARGS
|
||||
])
|
||||
|
|
|
@ -0,0 +1,35 @@
|
|||
dnl #
|
||||
dnl # Check for ioctl()
|
||||
dnl #
|
||||
AC_DEFUN([ZFS_AC_CONFIG_USER_IOCTL], [
|
||||
AC_MSG_CHECKING(checking for ioctl())
|
||||
AC_EGREP_HEADER(ioctl, unistd.h, is_unistd=yes, is_unistd=no)
|
||||
AC_EGREP_HEADER(ioctl, sys/ioctl.h, is_sys_ioctl=yes, is_sys_ioctl=no)
|
||||
AC_EGREP_HEADER(ioctl, stropts.h, is_stropts=yes, is_stropts=no)
|
||||
|
||||
if test $is_unistd = yes; then
|
||||
result=unistd.h
|
||||
AC_DEFINE([HAVE_IOCTL_IN_UNISTD_H], 1,
|
||||
[Define to 1 if ioctl() defined in <unistd.h>])
|
||||
else
|
||||
|
||||
if test $is_sys_ioctl = yes; then
|
||||
result=sys/ioctl.h
|
||||
AC_DEFINE([HAVE_IOCTL_IN_SYS_IOCTL_H], 1,
|
||||
[Define to 1 if ioctl() defined in <sys/ioctl.h>])
|
||||
elif test $is_stropts = yes; then
|
||||
AC_DEFINE([HAVE_IOCTL_IN_STROPTS_H], 1,
|
||||
result=stropts.h
|
||||
[Define to 1 if ioctl() defined in <stropts.h>])
|
||||
else
|
||||
result=no
|
||||
fi
|
||||
fi
|
||||
|
||||
if test $result = no; then
|
||||
AC_MSG_RESULT([no])
|
||||
AC_MSG_ERROR([*** Cannot locate ioctl() definition])
|
||||
else
|
||||
AC_MSG_RESULT(yes)
|
||||
fi
|
||||
])
|
|
@ -0,0 +1,8 @@
|
|||
dnl #
|
||||
dnl # Check for libdiskmgt
|
||||
dnl #
|
||||
AC_DEFUN([ZFS_AC_CONFIG_USER_LIBDISKMGT], [
|
||||
AC_CHECK_LIB([diskmgt], [libdiskmgt_error],
|
||||
[AC_DEFINE([HAVE_LIBDISKMGT], 1,
|
||||
[Define to 1 if 'libdiskmgt' library available])])
|
||||
])
|
|
@ -0,0 +1,8 @@
|
|||
dnl #
|
||||
dnl # Check for libefi
|
||||
dnl #
|
||||
AC_DEFUN([ZFS_AC_CONFIG_USER_LIBEFI], [
|
||||
AC_CHECK_LIB([efi], [efi_alloc_and_init],
|
||||
[AC_DEFINE([HAVE_LIBEFI], 1,
|
||||
[Define to 1 if 'libefi' library available])])
|
||||
])
|
|
@ -0,0 +1,8 @@
|
|||
dnl #
|
||||
dnl # Check for libshare
|
||||
dnl #
|
||||
AC_DEFUN([ZFS_AC_CONFIG_USER_LIBSHARE], [
|
||||
AC_CHECK_LIB([share], [sa_init],
|
||||
[AC_DEFINE([HAVE_LIBSHARE], 1,
|
||||
[Define to 1 if 'libshare' library available])])
|
||||
])
|
|
@ -3,5 +3,7 @@ dnl # Default ZFS user configuration
|
|||
dnl #
|
||||
AC_DEFUN([ZFS_AC_CONFIG_USER], [
|
||||
ZFS_AC_CONFIG_USER_LIBEFI
|
||||
ZFS_AC_CONFIG_USER_LIBDISKMGT
|
||||
ZFS_AC_CONFIG_USER_LIBSHARE
|
||||
ZFS_AC_CONFIG_USER_IOCTL
|
||||
])
|
||||
|
|
Loading…
Reference in New Issue