1178825Sdfrdnl $Id: auth-modules.m4 13338 2004-02-12 14:21:14Z lha $
255682Smarkmdnl
355682Smarkmdnl Figure what authentication modules should be built
4103423Snectardnl
5103423Snectardnl rk_AUTH_MODULES(module-list)
655682Smarkm
7127808SnectarAC_DEFUN([rk_AUTH_MODULES],[
8103423SnectarAC_MSG_CHECKING([which authentication modules should be built])
955682Smarkm
10103423Snectarz='m4_ifval([$1], $1, [sia pam afskauthlib])'
1155682SmarkmLIB_AUTH_SUBDIRS=
12103423Snectarfor i in $z; do
13103423Snectarcase $i in
14103423Snectarsia)
1555682Smarkmif test "$ac_cv_header_siad_h" = yes; then
1655682Smarkm	LIB_AUTH_SUBDIRS="$LIB_AUTH_SUBDIRS sia"
1755682Smarkmfi
18103423Snectar;;
19103423Snectarpam)
20102644Snectarcase "${host}" in
21102644Snectar*-*-freebsd*)	ac_cv_want_pam_krb4=no ;;
22102644Snectar*)		ac_cv_want_pam_krb4=yes ;;
23102644Snectaresac
24102644Snectar
25102644Snectarif test "$ac_cv_want_pam_krb4" = yes -a \
26102644Snectar    "$ac_cv_header_security_pam_modules_h" = yes -a \
27102644Snectar    "$enable_shared" = yes; then
2855682Smarkm	LIB_AUTH_SUBDIRS="$LIB_AUTH_SUBDIRS pam"
2955682Smarkmfi
30103423Snectar;;
31103423Snectarafskauthlib)
3255682Smarkmcase "${host}" in
3390926Snectar*-*-irix[[56]]*) LIB_AUTH_SUBDIRS="$LIB_AUTH_SUBDIRS afskauthlib" ;;
3455682Smarkmesac
35103423Snectar;;
36103423Snectaresac
37103423Snectardone
38103423Snectarif test "$LIB_AUTH_SUBDIRS"; then
39103423Snectar	AC_MSG_RESULT($LIB_AUTH_SUBDIRS)
40103423Snectarelse
41103423Snectar	AC_MSG_RESULT(none)
42103423Snectarfi
4355682Smarkm
4455682SmarkmAC_SUBST(LIB_AUTH_SUBDIRS)dnl
4555682Smarkm])
46