Lines 87-92
if test "$ac_cv_header_utmp_h" = "yes";
Link Here
|
87 |
fi |
87 |
fi |
88 |
|
88 |
|
89 |
if test "$ac_cv_header_lastlog_h" = "yes"; then |
89 |
if test "$ac_cv_header_lastlog_h" = "yes"; then |
|
|
90 |
|
90 |
AC_CACHE_CHECK(for ll_host in struct lastlog, |
91 |
AC_CACHE_CHECK(for ll_host in struct lastlog, |
91 |
ac_cv_struct_lastlog_ll_host, |
92 |
ac_cv_struct_lastlog_ll_host, |
92 |
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([#include <lastlog.h>], |
93 |
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([#include <lastlog.h>], |
Lines 331-336
if test "$with_selinux" != "no"; then
Link Here
|
331 |
fi |
332 |
fi |
332 |
fi |
333 |
fi |
333 |
|
334 |
|
|
|
335 |
|
334 |
AC_SUBST(LIBPAM) |
336 |
AC_SUBST(LIBPAM) |
335 |
if test "$with_libpam" != "no"; then |
337 |
if test "$with_libpam" != "no"; then |
336 |
AC_CHECK_LIB(pam, pam_start, |
338 |
AC_CHECK_LIB(pam, pam_start, |
Lines 339-351
if test "$with_libpam" != "no"; then
Link Here
|
339 |
AC_MSG_ERROR(libpam not found) |
341 |
AC_MSG_ERROR(libpam not found) |
340 |
fi |
342 |
fi |
341 |
|
343 |
|
342 |
AC_CHECK_LIB(pam_misc, main, |
344 |
LIBPAM="-lpam" |
343 |
[pam_misc_lib="yes"], [pam_misc_lib="no"]) |
345 |
pam_conv_function="no" |
344 |
if test "$pam_misc_lib$with_libpam" = "noyes" ; then |
346 |
|
345 |
AC_MSG_ERROR(libpam_misc not found) |
347 |
AC_CHECK_LIB(pam, openpam_ttyconv, |
|
|
348 |
[pam_conv_function="openpam_ttyconv"], |
349 |
AC_CHECK_LIB(pam_misc, misc_conv, |
350 |
[pam_conv_function="misc_conv"; LIBPAM="$LIBPAM -lpam_misc"]) |
351 |
) |
352 |
|
353 |
if test "$pam_conv_function$with_libpam" = "noyes" ; then |
354 |
AC_MSG_ERROR(PAM conversation function not found) |
346 |
fi |
355 |
fi |
347 |
|
356 |
|
348 |
if test "$pam_lib$pam_misc_lib" = "yesyes" ; then |
357 |
pam_headers_found=no |
|
|
358 |
AC_CHECK_HEADERS( [security/openpam.h security/pam_misc.h], |
359 |
[ pam_headers_found=yes ; break ], [], |
360 |
[ #include <security/pam_appl.h> ] ) |
361 |
if test "$pam_headers_found$with_libpam" = "noyes" ; then |
362 |
AC_MSG_ERROR(PAM headers not found) |
363 |
fi |
364 |
|
365 |
|
366 |
if test "$pam_lib$pam_headers_found" = "yesyes" -a "$pam_conv_function" != "no" ; then |
349 |
with_libpam="yes" |
367 |
with_libpam="yes" |
350 |
else |
368 |
else |
351 |
with_libpam="no" |
369 |
with_libpam="no" |
Lines 353-361
if test "$with_libpam" != "no"; then
Link Here
|
353 |
fi |
371 |
fi |
354 |
dnl Now with_libpam is either yes or no |
372 |
dnl Now with_libpam is either yes or no |
355 |
if test "$with_libpam" = "yes"; then |
373 |
if test "$with_libpam" = "yes"; then |
|
|
374 |
AC_CHECK_DECLS([PAM_ESTABLISH_CRED, |
375 |
PAM_DELETE_CRED, |
376 |
PAM_NEW_AUTHTOK_REQD, |
377 |
PAM_DATA_SILENT], |
378 |
[], [], [#include <security/pam_appl.h>]) |
379 |
|
380 |
|
381 |
save_libs=$LIBS |
382 |
LIBS="$LIBS $LIBPAM" |
383 |
AC_CHECK_FUNCS([pam_fail_delay]) |
384 |
LIBS=$save_libs |
385 |
|
356 |
AC_DEFINE(USE_PAM, 1, [Define to support Pluggable Authentication Modules]) |
386 |
AC_DEFINE(USE_PAM, 1, [Define to support Pluggable Authentication Modules]) |
|
|
387 |
AC_DEFINE_UNQUOTED(SHADOW_PAM_CONVERSATION, [$pam_conv_function],[PAM converstation to use]) |
357 |
AM_CONDITIONAL(USE_PAM, [true]) |
388 |
AM_CONDITIONAL(USE_PAM, [true]) |
358 |
LIBPAM="-lpam -lpam_misc" |
389 |
|
359 |
AC_MSG_CHECKING(use login and su access checking if PAM not used) |
390 |
AC_MSG_CHECKING(use login and su access checking if PAM not used) |
360 |
AC_MSG_RESULT(no) |
391 |
AC_MSG_RESULT(no) |
361 |
else |
392 |
else |