]>
Commit | Line | Data |
---|---|---|
1 | Index: configure.in | |
2 | =================================================================== | |
3 | RCS file: /cvsroot/shadow/configure.in,v | |
4 | retrieving revision 1.150 | |
5 | diff -u -p -r1.150 configure.in | |
6 | --- configure.in 3 Aug 2006 10:14:05 -0000 1.150 | |
7 | +++ configure.in 5 Aug 2006 18:51:34 -0000 | |
8 | @@ -220,7 +220,7 @@ AC_ARG_WITH(libpam, | |
9 | [with_libpam=$withval], [with_libpam=yes]) | |
10 | AC_ARG_WITH(selinux, | |
11 | [AC_HELP_STRING([--with-selinux], [use SELinux support @<:@default=autodetect@:>@])], | |
12 | - [with_selinux=$withval], [with_selinux=yes]) | |
13 | + [with_selinux=$withval], [with_selinux=maybe]) | |
14 | AC_ARG_WITH(skey, | |
15 | [AC_HELP_STRING([--with-skey], [use S/Key support @<:@default=no@:>@])], | |
16 | [with_skey=$withval], [with_skey=no]) | |
17 | @@ -282,15 +282,21 @@ if test "$with_libcrack" = "yes"; then | |
18 | AC_DEFINE(HAVE_LIBCRACK_PW, 1, [Defined if it includes *Pw functions.])) | |
19 | fi | |
20 | ||
21 | -if test "$with_selinux" = "yes"; then | |
22 | +if test "$with_selinux" != "no" ; then | |
23 | + have_selinux="yes" | |
24 | AC_CHECK_LIB(selinux, is_selinux_enabled, | |
25 | [LIBSELINUX="-lselinux" | |
26 | AC_SUBST(LIBSELINUX) | |
27 | AC_CHECK_HEADERS(selinux/selinux.h, [], | |
28 | - [AC_MSG_ERROR([selinux/selinux.h is missing])]) | |
29 | + [have_selinux="no"]) | |
30 | AC_DEFINE(WITH_SELINUX, 1, [Build shadow with SELinux support]) | |
31 | ], | |
32 | - [AC_MSG_ERROR([libselinux not found])]) | |
33 | + [have_selinux="no"]) | |
34 | + if test "x$have_selinux$with_selinux" = "xnoyes" ; then | |
35 | + AC_MSG_ERROR([selinux support not found]) | |
36 | + else | |
37 | + with_selinux="$have_selinux" | |
38 | + fi | |
39 | fi | |
40 | ||
41 | AC_SUBST(LIBPAM) |