summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog4
-rw-r--r--configure.ac117
2 files changed, 61 insertions, 60 deletions
diff --git a/ChangeLog b/ChangeLog
index 84c0bd419..dc43a0544 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -2,6 +2,8 @@
2 - (dtucker) [log.c] Move ifdef to prevent unused variable warning. 2 - (dtucker) [log.c] Move ifdef to prevent unused variable warning.
3 - (dtucker) [configure.ac] Save $LIBS during PAM library tests and restore 3 - (dtucker) [configure.ac] Save $LIBS during PAM library tests and restore
4 afterward. Removes the need to mangle $LIBS later to remove -lpam and -ldl. 4 afterward. Removes the need to mangle $LIBS later to remove -lpam and -ldl.
5 - (dtucker) [configure.ac] Relocate --with-pam parts in preparation for
6 fixing bug #1181. No changes yet.
5 7
620060819 820060819
7 - (djm) OpenBSD CVS Sync 9 - (djm) OpenBSD CVS Sync
@@ -5279,4 +5281,4 @@
5279 - (djm) Trim deprecated options from INSTALL. Mention UsePAM 5281 - (djm) Trim deprecated options from INSTALL. Mention UsePAM
5280 - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu 5282 - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
5281 5283
5282$Id: ChangeLog,v 1.4500 2006/08/20 09:55:02 dtucker Exp $ 5284$Id: ChangeLog,v 1.4501 2006/08/20 10:03:50 dtucker Exp $
diff --git a/configure.ac b/configure.ac
index 17de2173a..a3eec9520 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,4 +1,4 @@
1# $Id: configure.ac,v 1.352 2006/08/20 09:55:02 dtucker Exp $ 1# $Id: configure.ac,v 1.353 2006/08/20 10:03:50 dtucker Exp $
2# 2#
3# Copyright (c) 1999-2004 Damien Miller 3# Copyright (c) 1999-2004 Damien Miller
4# 4#
@@ -15,7 +15,7 @@
15# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 15# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16 16
17AC_INIT(OpenSSH, Portable, openssh-unix-dev@mindrot.org) 17AC_INIT(OpenSSH, Portable, openssh-unix-dev@mindrot.org)
18AC_REVISION($Revision: 1.352 $) 18AC_REVISION($Revision: 1.353 $)
19AC_CONFIG_SRCDIR([ssh.c]) 19AC_CONFIG_SRCDIR([ssh.c])
20 20
21AC_CONFIG_HEADER(config.h) 21AC_CONFIG_HEADER(config.h)
@@ -1680,63 +1680,6 @@ fi
1680 1680
1681AC_FUNC_GETPGRP 1681AC_FUNC_GETPGRP
1682 1682
1683# Check for PAM libs
1684PAM_MSG="no"
1685AC_ARG_WITH(pam,
1686 [ --with-pam Enable PAM support ],
1687 [
1688 if test "x$withval" != "xno" ; then
1689 if test "x$ac_cv_header_security_pam_appl_h" != "xyes" && \
1690 test "x$ac_cv_header_pam_pam_appl_h" != "xyes" ; then
1691 AC_MSG_ERROR([PAM headers not found])
1692 fi
1693
1694 saved_LIBS="$LIBS"
1695 AC_CHECK_LIB(dl, dlopen, , )
1696 AC_CHECK_LIB(pam, pam_set_item, , AC_MSG_ERROR([*** libpam missing]))
1697 AC_CHECK_FUNCS(pam_getenvlist)
1698 AC_CHECK_FUNCS(pam_putenv)
1699 LIBS="$saved_LIBS"
1700
1701 PAM_MSG="yes"
1702
1703 AC_DEFINE(USE_PAM, 1,
1704 [Define if you want to enable PAM support])
1705 if test $ac_cv_lib_dl_dlopen = yes; then
1706 LIBPAM="-lpam -ldl"
1707 else
1708 LIBPAM="-lpam"
1709 fi
1710 AC_SUBST(LIBPAM)
1711 fi
1712 ]
1713)
1714
1715# Check for older PAM
1716if test "x$PAM_MSG" = "xyes" ; then
1717 # Check PAM strerror arguments (old PAM)
1718 AC_MSG_CHECKING([whether pam_strerror takes only one argument])
1719 AC_TRY_COMPILE(
1720 [
1721#include <stdlib.h>
1722#if defined(HAVE_SECURITY_PAM_APPL_H)
1723#include <security/pam_appl.h>
1724#elif defined (HAVE_PAM_PAM_APPL_H)
1725#include <pam/pam_appl.h>
1726#endif
1727 ],
1728 [(void)pam_strerror((pam_handle_t *)NULL, -1);],
1729 [AC_MSG_RESULT(no)],
1730 [
1731 AC_DEFINE(HAVE_OLD_PAM, 1,
1732 [Define if you have an old version of PAM
1733 which takes only one argument to pam_strerror])
1734 AC_MSG_RESULT(yes)
1735 PAM_MSG="yes (old library)"
1736 ]
1737 )
1738fi
1739
1740# Search for OpenSSL 1683# Search for OpenSSL
1741saved_CPPFLAGS="$CPPFLAGS" 1684saved_CPPFLAGS="$CPPFLAGS"
1742saved_LDFLAGS="$LDFLAGS" 1685saved_LDFLAGS="$LDFLAGS"
@@ -1963,6 +1906,62 @@ int main(void) { exit(RAND_status() == 1 ? 0 : 1); }
1963 ] 1906 ]
1964) 1907)
1965 1908
1909# Check for PAM libs
1910PAM_MSG="no"
1911AC_ARG_WITH(pam,
1912 [ --with-pam Enable PAM support ],
1913 [
1914 if test "x$withval" != "xno" ; then
1915 if test "x$ac_cv_header_security_pam_appl_h" != "xyes" && \
1916 test "x$ac_cv_header_pam_pam_appl_h" != "xyes" ; then
1917 AC_MSG_ERROR([PAM headers not found])
1918 fi
1919
1920 saved_LIBS="$LIBS"
1921 AC_CHECK_LIB(dl, dlopen, , )
1922 AC_CHECK_LIB(pam, pam_set_item, , AC_MSG_ERROR([*** libpam missing]))
1923 AC_CHECK_FUNCS(pam_getenvlist)
1924 AC_CHECK_FUNCS(pam_putenv)
1925 LIBS="$saved_LIBS"
1926
1927 PAM_MSG="yes"
1928
1929 AC_DEFINE(USE_PAM, 1,
1930 [Define if you want to enable PAM support])
1931 if test $ac_cv_lib_dl_dlopen = yes; then
1932 LIBPAM="-lpam -ldl"
1933 else
1934 LIBPAM="-lpam"
1935 fi
1936 AC_SUBST(LIBPAM)
1937 fi
1938 ]
1939)
1940
1941# Check for older PAM
1942if test "x$PAM_MSG" = "xyes" ; then
1943 # Check PAM strerror arguments (old PAM)
1944 AC_MSG_CHECKING([whether pam_strerror takes only one argument])
1945 AC_TRY_COMPILE(
1946 [
1947#include <stdlib.h>
1948#if defined(HAVE_SECURITY_PAM_APPL_H)
1949#include <security/pam_appl.h>
1950#elif defined (HAVE_PAM_PAM_APPL_H)
1951#include <pam/pam_appl.h>
1952#endif
1953 ],
1954 [(void)pam_strerror((pam_handle_t *)NULL, -1);],
1955 [AC_MSG_RESULT(no)],
1956 [
1957 AC_DEFINE(HAVE_OLD_PAM, 1,
1958 [Define if you have an old version of PAM
1959 which takes only one argument to pam_strerror])
1960 AC_MSG_RESULT(yes)
1961 PAM_MSG="yes (old library)"
1962 ]
1963 )
1964fi
1966 1965
1967# Do we want to force the use of the rand helper? 1966# Do we want to force the use of the rand helper?
1968AC_ARG_WITH(rand-helper, 1967AC_ARG_WITH(rand-helper,