]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
build: suppress an erroneous warning --with-selinux=no
authorPádraig Brady <P@draigBrady.com>
Tue, 21 Jan 2014 10:13:32 +0000 (10:13 +0000)
committerPádraig Brady <P@draigBrady.com>
Tue, 21 Jan 2014 11:03:34 +0000 (11:03 +0000)
* m4/jm-macros.m4: Don't check the SELinux cached variables
--without-selinux.
Reported-by: Bernhard Voelker
m4/jm-macros.m4

index cb9e90ee2e98936c00428235e6b058d663b6061a..a96ecabb60c3d0614ed71cd1285d485709499eb7 100644 (file)
@@ -51,15 +51,17 @@ AC_DEFUN([coreutils_MACROS],
     # Used by install.c.
     AC_CHECK_FUNCS([matchpathcon_init_prefix], [],
     [
-      case "$ac_cv_search_setfilecon:$ac_cv_header_selinux_selinux_h" in
-        no:*) # SELinux disabled
-          ;;
-        *:no) # SELinux disabled
-          ;;
-        *)
-        AC_MSG_WARN([SELinux enabled, but matchpathcon_init_prefix not found])
-        AC_MSG_WARN([The install utility may run slowly])
-      esac
+      if test "$with_selinux" != no; then
+        case "$ac_cv_search_setfilecon:$ac_cv_header_selinux_selinux_h" in
+          no:*) # SELinux disabled
+            ;;
+          *:no) # SELinux disabled
+            ;;
+          *)
+          AC_MSG_WARN([SELinux enabled, but matchpathcon_init_prefix not found])
+          AC_MSG_WARN([The install utility may run slowly])
+        esac
+      fi
     ])
   LIBS=$coreutils_saved_libs