]> granicus.if.org Git - sudo/commitdiff
Some PAM implementations put their headers in /usr/include/pam instead
authorTodd C. Miller <Todd.Miller@courtesan.com>
Fri, 9 Jan 2004 19:35:54 +0000 (19:35 +0000)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Fri, 9 Jan 2004 19:35:54 +0000 (19:35 +0000)
of /usr/include/security.

auth/pam.c
config.h.in
configure
configure.in

index c8d83e2bf21d9fbb16b156cc9f003d108fc37dfe..1561a8642cf87de3f997152de6ba2ec68d22aeb1 100644 (file)
 #endif /* HAVE_UNISTD_H */
 #include <pwd.h>
 
-#include <security/pam_appl.h>
+#ifdef HAVE_PAM_PAM_APPL_H
+# include <pam/pam_appl.h>
+#else
+# include <security/pam_appl.h>
+#endif
 
 #include "sudo.h"
 #include "sudo_auth.h"
index 46769f5d4bf77ae86e7538f614ddd5efd47c9985..8dfbaa692a181eee341442d0f4c34522674fb461 100644 (file)
 /* Define if you use PAM. */
 #undef HAVE_PAM
 
+/* Define to 1 if you have the <pam/pam_appl.h> header file. */
+#undef HAVE_PAM_PAM_APPL_H
+
 /* Define to 1 if you have the <paths.h> header file. */
 #undef HAVE_PATHS_H
 
index 9ef902bfe6848b6fd772056f9da8d7e099fe6644..3cbe8904341300a284d55bf1f1626fcbaf4ee87a 100755 (executable)
--- a/configure
+++ b/configure
@@ -8534,24 +8534,31 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       ;;
 
     openbsd*)
-      hardcode_direct=yes
-      hardcode_shlibpath_var=no
-      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-       archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-       hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
-       export_dynamic_flag_spec='${wl}-E'
-      else
-       case $host_os in
-        openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
-          archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
-          hardcode_libdir_flag_spec='-R$libdir'
-          ;;
-        *)
-          archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-          hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
-          ;;
-       esac
-      fi
+      case "$host_cpu" in
+       m88k|hppa|vax)
+         ld_shlibs=no
+         ;;
+       *)
+         hardcode_direct=yes
+         hardcode_shlibpath_var=no
+         if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
+           archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+           hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
+           export_dynamic_flag_spec='${wl}-E'
+         else
+           case $host_os in
+             openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
+               archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
+               hardcode_libdir_flag_spec='-R$libdir'
+               ;;
+             *)
+               archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+               hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
+               ;;
+           esac
+         fi
+          ;;
+      esac
       ;;
 
     os2*)
@@ -9848,7 +9855,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 9851 "configure"
+#line 9858 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -9946,7 +9953,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 9949 "configure"
+#line 9956 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -12082,11 +12089,11 @@ else
    -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:12085: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:12092: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:12089: \$? = $ac_status" >&5
+   echo "$as_me:12096: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
@@ -12149,11 +12156,11 @@ else
    -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:12152: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:12159: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:12156: \$? = $ac_status" >&5
+   echo "$as_me:12163: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -13353,7 +13360,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 13356 "configure"
+#line 13363 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -13451,7 +13458,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 13454 "configure"
+#line 13461 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -14273,11 +14280,11 @@ else
    -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:14276: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:14283: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:14280: \$? = $ac_status" >&5
+   echo "$as_me:14287: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
@@ -14340,11 +14347,11 @@ else
    -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:14343: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:14350: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:14347: \$? = $ac_status" >&5
+   echo "$as_me:14354: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -14977,24 +14984,31 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       ;;
 
     openbsd*)
-      hardcode_direct_F77=yes
-      hardcode_shlibpath_var_F77=no
-      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-       archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-       hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir'
-       export_dynamic_flag_spec_F77='${wl}-E'
-      else
-       case $host_os in
-        openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
-          archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
-          hardcode_libdir_flag_spec_F77='-R$libdir'
-          ;;
-        *)
-          archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-          hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir'
-          ;;
-       esac
-      fi
+      case "$host_cpu" in
+       m88k|hppa|vax)
+         ld_shlibs_F77=no
+         ;;
+       *)
+         hardcode_direct_F77=yes
+         hardcode_shlibpath_var_F77=no
+         if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
+           archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+           hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir'
+           export_dynamic_flag_spec_F77='${wl}-E'
+         else
+           case $host_os in
+             openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
+               archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
+               hardcode_libdir_flag_spec_F77='-R$libdir'
+               ;;
+             *)
+               archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+               hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir'
+               ;;
+           esac
+         fi
+          ;;
+      esac
       ;;
 
     os2*)
@@ -16245,11 +16259,11 @@ else
    -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:16248: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:16262: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:16252: \$? = $ac_status" >&5
+   echo "$as_me:16266: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
@@ -16477,11 +16491,11 @@ else
    -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:16480: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:16494: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "$as_me:16484: \$? = $ac_status" >&5
+   echo "$as_me:16498: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s "$ac_outfile"; then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
@@ -16544,11 +16558,11 @@ else
    -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"\$as_me:16547: $lt_compile\"" >&5)
+   (eval echo "\"\$as_me:16561: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "$as_me:16551: \$? = $ac_status" >&5
+   echo "$as_me:16565: \$? = $ac_status" >&5
    if (exit $ac_status) && test -s out/conftest2.$ac_objext
    then
      # The compiler can only warn and ignore the option if not recognized
@@ -17203,24 +17217,31 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       ;;
 
     openbsd*)
-      hardcode_direct_GCJ=yes
-      hardcode_shlibpath_var_GCJ=no
-      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-       archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-       hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir'
-       export_dynamic_flag_spec_GCJ='${wl}-E'
-      else
-       case $host_os in
-        openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
-          archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
-          hardcode_libdir_flag_spec_GCJ='-R$libdir'
-          ;;
-        *)
-          archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-          hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir'
-          ;;
-       esac
-      fi
+      case "$host_cpu" in
+       m88k|hppa|vax)
+         ld_shlibs_GCJ=no
+         ;;
+       *)
+         hardcode_direct_GCJ=yes
+         hardcode_shlibpath_var_GCJ=no
+         if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
+           archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+           hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir'
+           export_dynamic_flag_spec_GCJ='${wl}-E'
+         else
+           case $host_os in
+             openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
+               archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
+               hardcode_libdir_flag_spec_GCJ='-R$libdir'
+               ;;
+             *)
+               archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+               hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir'
+               ;;
+           esac
+         fi
+          ;;
+      esac
       ;;
 
     os2*)
@@ -18517,7 +18538,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 18520 "configure"
+#line 18541 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -18615,7 +18636,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 18618 "configure"
+#line 18639 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -28540,7 +28561,7 @@ rm -f conftest.$ac_objext conftest.$ac_ext
 fi
 
 if test "$with_pam" = "yes"; then
-    echo "$as_me:$LINENO: checking for main in -ldl" >&5
+                echo "$as_me:$LINENO: checking for main in -ldl" >&5
 echo $ECHO_N "checking for main in -ldl... $ECHO_C" >&6
 if test "${ac_cv_lib_dl_main+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -28595,6 +28616,148 @@ else
 fi
 ac_cv_lib_dl=ac_cv_lib_dl_main
 
+
+for ac_header in pam/pam_appl.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+  echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+else
+  # Is the header compilable?
+echo "$as_me:$LINENO: checking $ac_header usability" >&5
+echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+$ac_includes_default
+#include <$ac_header>
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+         { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_header_compiler=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_header_compiler=no
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6
+
+# Is the header present?
+echo "$as_me:$LINENO: checking $ac_header presence" >&5
+echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#include <$ac_header>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null; then
+  if test -s conftest.err; then
+    ac_cpp_err=$ac_c_preproc_warn_flag
+  else
+    ac_cpp_err=
+  fi
+else
+  ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+  ac_header_preproc=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+  ac_header_preproc=no
+fi
+rm -f conftest.err conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6
+
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc in
+  yes:no )
+    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+    (
+      cat <<\_ASBOX
+## ------------------------------------ ##
+## Report this to bug-autoconf@gnu.org. ##
+## ------------------------------------ ##
+_ASBOX
+    ) |
+      sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+  no:yes )
+    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+    (
+      cat <<\_ASBOX
+## ------------------------------------ ##
+## Report this to bug-autoconf@gnu.org. ##
+## ------------------------------------ ##
+_ASBOX
+    ) |
+      sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  eval "$as_ac_Header=$ac_header_preproc"
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+
+fi
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+
+fi
+
+done
+
 fi
 
 if test "$with_AFS" = "yes"; then
index 30b5368ad1726ebc6b1a4d91f986dc8148139b57..e12399ab3f22f10c042600dea0a4e3507f978a9d 100644 (file)
@@ -1864,10 +1864,18 @@ if test -n "$with_kerb5" -a -z "$KRB5CONFIG"; then
 fi
 
 dnl
-dnl PAM libs
+dnl Extra PAM foolishness
 dnl
 if test "$with_pam" = "yes"; then
+    dnl
+    dnl Linux may need this
+    dnl
     AC_HAVE_LIBRARY(dl, SUDO_LIBS="${SUDO_LIBS} -lpam -ldl", SUDO_LIBS="${SUDO_LIBS} -lpam")
+    dnl
+    dnl Some PAM implementations (MacOS X for example) put the PAM headers
+    dnl in /usr/include/pam instead of /usr/include/security...
+    dnl
+    AC_CHECK_HEADERS([pam/pam_appl.h])
 fi
 
 dnl