blob: a6ccfb6a8743f0c87857750c0099615b28f9c804 [file] [log] [blame]
Brad Bishop1a4b7ee2018-12-16 17:11:34 -08001From 166cbc02f72d13d5e7bf08ac2351c0f07e1ff4b9 Mon Sep 17 00:00:00 2001
2From: Wenzong Fan <wenzong.fan@windriver.com>
3Date: Mon, 1 Dec 2014 02:08:27 -0500
4Subject: [PATCH] apache2: allow to disable selinux support
5
6Upstream-Status: Pending
7
8Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
9
10---
11 configure.in | 14 ++++++++++----
12 1 file changed, 10 insertions(+), 4 deletions(-)
13
14diff --git a/configure.in b/configure.in
15index 54dfd0d..377e062 100644
16--- a/configure.in
17+++ b/configure.in
18@@ -466,10 +466,16 @@ getloadavg
19 dnl confirm that a void pointer is large enough to store a long integer
20 APACHE_CHECK_VOID_PTR_LEN
21
22-AC_CHECK_LIB(selinux, is_selinux_enabled, [
23- AC_DEFINE(HAVE_SELINUX, 1, [Defined if SELinux is supported])
24- APR_ADDTO(AP_LIBS, [-lselinux])
25-])
26+# SELinux support
27+AC_ARG_ENABLE(selinux,APACHE_HELP_STRING(--enable-selinux,Enable SELinux support [default=auto]),
28+ [],[enable_selinux=auto])
29+
30+if test x$enable_selinux != xno; then
31+ AC_CHECK_LIB(selinux, is_selinux_enabled, [
32+ AC_DEFINE(HAVE_SELINUX, 1, [Defined if SELinux is supported])
33+ APR_ADDTO(AP_LIBS, [-lselinux])
34+ ])
35+fi
36
37 AC_CACHE_CHECK([for gettid()], ac_cv_gettid,
38 [AC_TRY_RUN(#define _GNU_SOURCE