Add -p switch to "zpool get"
[zfs.git] / config / user-selinux.m4
1 dnl #
2 dnl # Check to see if the selinux libraries are available.  If they
3 dnl # are then they will be consulted during mount to determine if
4 dnl # selinux is enabled or disabled.
5 dnl #
6 AC_DEFUN([ZFS_AC_CONFIG_USER_LIBSELINUX], [
7         AC_ARG_WITH([selinux],
8                 [AS_HELP_STRING([--with-selinux],
9                 [support selinux @<:@default=check@:>@])],
10                 [],
11                 [with_selinux=check])
12
13         LIBSELINUX=
14         AS_IF([test "x$with_selinux" != xno], [
15                 AC_CHECK_HEADER([selinux/selinux.h], [
16                         AC_CHECK_LIB([selinux], [is_selinux_enabled], [
17                                 AC_SUBST([LIBSELINUX], ["-lselinux"])
18                                 AC_DEFINE([HAVE_LIBSELINUX], 1,
19                                         [Define if you have selinux])
20                         ], [
21                                 AS_IF([test "x$with_selinux" != xcheck],
22                                         [AC_MSG_FAILURE(
23                                         [--with-selinux given but unavailable])
24                                 ])
25                         ])
26                 ], [
27                         AS_IF([test "x$with_selinux" != xcheck],
28                                 [AC_MSG_FAILURE(
29                                 [--with-selinux given but unavailable])
30                         ])
31                 ])
32         ], [
33                 AC_MSG_CHECKING([for selinux support])
34                 AC_MSG_RESULT([no])
35         ])
36 ])