1dnl # SPDX-License-Identifier: CDDL-1.0 2dnl # 3dnl # Check for mount_setattr() and struct mount_attr availability 4dnl # 5AC_DEFUN([ZFS_AC_CONFIG_USER_MOUNT_SETATTR], [ 6 AC_CHECK_FUNC([mount_setattr], [ 7 AC_MSG_CHECKING([for struct mount_attr]) 8 AC_COMPILE_IFELSE([ 9 AC_LANG_PROGRAM([[ 10 #include <sys/mount.h> 11 ]], [[ 12 struct mount_attr attr = { 13 .attr_set = MOUNT_ATTR_RDONLY, 14 .attr_clr = MOUNT_ATTR_NOEXEC, 15 }; 16 (void) attr; 17 ]]) 18 ], [ 19 AC_MSG_RESULT([yes]) 20 AC_DEFINE([HAVE_MOUNT_SETATTR], [1], 21 [mount_setattr() and struct mount_attr 22 are available]) 23 ], [ 24 AC_MSG_RESULT([no]) 25 ]) 26 ]) 27]) 28