summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2001-02-19 12:56:39 +1100
committerDamien Miller <djm@mindrot.org>2001-02-19 12:56:39 +1100
commitccdefb600f9d279cd17cdca79b241a036b380b21 (patch)
tree4a31dd7b6600ca97b1122b29e10d5cb72e2170eb
parentd95c09cc83ec07b42feb07c4ff71d23720b37e8e (diff)
- (djm) Rework search for OpenSSL location. Skip directories which don't
exist, don't add -L$ssldir/lib if it doesn't exist. Should help SCO with its limit of 6 -L options.
-rw-r--r--ChangeLog5
-rw-r--r--configure.in63
2 files changed, 50 insertions, 18 deletions
diff --git a/ChangeLog b/ChangeLog
index be687ffcb..5b3d94b16 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,9 @@
120010219 120010219
2 - (bal) Markus' blessing to rename login.[ch] -> sshlogin.[ch] and 2 - (bal) Markus' blessing to rename login.[ch] -> sshlogin.[ch] and
3 pty.[ch] -> sshpty.[ch] 3 pty.[ch] -> sshpty.[ch]
4 - (djm) Rework search for OpenSSL location. Skip directories which don't
5 exist, don't add -L$ssldir/lib if it doesn't exist. Should help SCO
6 with its limit of 6 -L options.
4 7
520010218 820010218
6 - (bal) Patch for fix FCHMOD reference in ftp-client.c by Tim Rice 9 - (bal) Patch for fix FCHMOD reference in ftp-client.c by Tim Rice
@@ -4042,4 +4045,4 @@
4042 - Wrote replacements for strlcpy and mkdtemp 4045 - Wrote replacements for strlcpy and mkdtemp
4043 - Released 1.0pre1 4046 - Released 1.0pre1
4044 4047
4045$Id: ChangeLog,v 1.801 2001/02/18 19:13:33 mouring Exp $ 4048$Id: ChangeLog,v 1.802 2001/02/19 01:56:39 djm Exp $
diff --git a/configure.in b/configure.in
index a5870f336..29c482396 100644
--- a/configure.in
+++ b/configure.in
@@ -1,4 +1,4 @@
1# $Id: configure.in,v 1.247 2001/02/18 06:01:00 djm Exp $ 1# $Id: configure.in,v 1.248 2001/02/19 01:56:39 djm Exp $
2 2
3AC_INIT(ssh.c) 3AC_INIT(ssh.c)
4 4
@@ -593,20 +593,38 @@ if test "x$prefix" != "xNONE" ; then
593 tryssldir="$tryssldir $prefix" 593 tryssldir="$tryssldir $prefix"
594fi 594fi
595AC_CACHE_CHECK([for OpenSSL directory], ac_cv_openssldir, [ 595AC_CACHE_CHECK([for OpenSSL directory], ac_cv_openssldir, [
596
597 for ssldir in $tryssldir "" /usr/local/openssl /usr/lib/openssl /usr/local/ssl /usr/lib/ssl /usr/local /usr/pkg /opt /opt/openssl ; do 596 for ssldir in $tryssldir "" /usr/local/openssl /usr/lib/openssl /usr/local/ssl /usr/lib/ssl /usr/local /usr/pkg /opt /opt/openssl ; do
597 CPPFLAGS="$saved_CPPFLAGS"
598 LDFLAGS="$saved_LDFLAGS"
599 LIBS="$saved_LIBS -lcrypto"
600
601 # Skip directories if they don't exist
602 if test ! -z "$ssldir" -a ! -d "$ssldir" ; then
603 continue;
604 fi
598 if test ! -z "$ssldir" -a "x$ssldir" != "x/usr"; then 605 if test ! -z "$ssldir" -a "x$ssldir" != "x/usr"; then
599 LDFLAGS="$saved_LDFLAGS -L$ssldir/lib -L$ssldir" 606 # Try to use $ssldir/lib if it exists, otherwise
600 CPPFLAGS="$saved_CPPFLAGS -I$ssldir/include" 607 # $ssldir
601 if test ! -z "$need_dash_r" ; then 608 if test -d "$ssldir/lib" ; then
602 LDFLAGS="$LDFLAGS -R$ssldir/lib -R$ssldir" 609 LDFLAGS="$LDFLAGS -L$ssldir/lib"
610 if test ! -z "$need_dash_r" ; then
611 LDFLAGS="$LDFLAGS -R$ssldir/lib"
612 fi
613 else
614 LDFLAGS="$LDFLAGS -L$ssldir"
615 if test ! -z "$need_dash_r" ; then
616 LDFLAGS="$LDFLAGS -R$ssldir"
617 fi
618 fi
619 # Try to use $ssldir/include if it exists, otherwise
620 # $ssldir
621 if test -d "$ssldir/include" ; then
622 CPPFLAGS="$CPPFLAGS -I$ssldir/include"
623 else
624 CPPFLAGS="$CPPFLAGS -I$ssldir"
603 fi 625 fi
604 else
605 LDFLAGS="$saved_LDFLAGS"
606 fi 626 fi
607 627
608 LIBS="$saved_LIBS -lcrypto"
609
610 # Basic test to check for compatible version and correct linking 628 # Basic test to check for compatible version and correct linking
611 # *does not* test for RSA - that comes later. 629 # *does not* test for RSA - that comes later.
612 AC_TRY_RUN( 630 AC_TRY_RUN(
@@ -646,15 +664,26 @@ if (test ! -z "$ac_cv_openssldir" && test "x$ac_cv_openssldir" != "x(system)") ;
646 AC_DEFINE(HAVE_OPENSSL) 664 AC_DEFINE(HAVE_OPENSSL)
647 dnl Need to recover ssldir - test above runs in subshell 665 dnl Need to recover ssldir - test above runs in subshell
648 ssldir=$ac_cv_openssldir 666 ssldir=$ac_cv_openssldir
649
650 if test ! -z "$ssldir" -a "x$ssldir" != "x/usr"; then 667 if test ! -z "$ssldir" -a "x$ssldir" != "x/usr"; then
651 CPPFLAGS="$saved_CPPFLAGS -I$ssldir/include" 668 # Try to use $ssldir/lib if it exists, otherwise
652 LDFLAGS="$saved_LDFLAGS -L$ssldir/lib -L$ssldir" 669 # $ssldir
653 if test ! -z "$need_dash_r" ; then 670 if test -d "$ssldir/lib" ; then
654 LDFLAGS="$LDFLAGS -R$ssldir/lib -R$ssldir" 671 LDFLAGS="$LDFLAGS -L$ssldir/lib"
672 if test ! -z "$need_dash_r" ; then
673 LDFLAGS="$LDFLAGS -R$ssldir/lib"
674 fi
675 else
676 LDFLAGS="$LDFLAGS -L$ssldir"
677 if test ! -z "$need_dash_r" ; then
678 LDFLAGS="$LDFLAGS -R$ssldir"
679 fi
655 fi 680 fi
656 if test ! -z "$blibpath" ; then 681 # Try to use $ssldir/include if it exists, otherwise
657 blibpath="$blibpath:$ssldir:$ssldir/lib" 682 # $ssldir
683 if test -d "$ssldir/include" ; then
684 CPPFLAGS="$CPPFLAGS -I$ssldir/include"
685 else
686 CPPFLAGS="$CPPFLAGS -I$ssldir"
658 fi 687 fi
659 fi 688 fi
660fi 689fi