From: Guy Harris Date: Tue, 24 Mar 2009 15:42:47 +0000 (-0700) Subject: From Michael Riepe: X-Git-Tag: tcpdump-4.1.0~132 X-Git-Url: https://git.tcpdump.org/tcpdump/commitdiff_plain/fbb3b4f6ef63d63d9857c75c580023c6f9d49652?ds=inline From Michael Riepe: On e.g. an x86_64 Linux system, configure won't find libcrypto because it's located in .../lib64. As a temporal workaround, use the last part of $libdir instead of "lib". On the long run, AC_LBL_SSLEAY should probably be rewritten. --- diff --git a/CREDITS b/CREDITS index 76ed39be..ed82f792 100644 --- a/CREDITS +++ b/CREDITS @@ -108,6 +108,7 @@ Additional people who have contributed patches: Max Laier Michael A. Meffie III Michael Madore + Michael Riepe Michael Shalayeff Michael Shields Michael T. Stolarchuk diff --git a/aclocal.m4 b/aclocal.m4 index 346bda8f..5126c700 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -1261,6 +1261,16 @@ AC_MSG_RESULT($ac_cv___attribute__) AC_DEFUN(AC_LBL_SSLEAY, [ + # + # Find the last component of $libdir; it's not necessarily + # "lib" - it might be "lib64" on, for example, x86-64 + # Linux systems. + # + # We assume the directory in which we're looking for + # libcrypto has a subdirectory with that as its name. + # + tmplib=`echo "$libdir" | sed 's,.*/,,'` + # # XXX - is there a better way to check if a given library is # in a given directory than checking each of the possible @@ -1271,10 +1281,10 @@ AC_DEFUN(AC_LBL_SSLEAY, # # Or should we just look for "libcrypto.*"? # - if test -d "$1/lib" -a \( -f "$1/lib/libcrypto.a" -o \ - -f "$1/lib/libcrypto.so" -o \ - -f "$1/lib/libcrypto.sl" -o \ - -f "$1/lib/libcrypto.dylib" \); then + if test -d "$1/$tmplib" -a \( -f "$1/$tmplib/libcrypto.a" -o \ + -f "$1/$tmplib/libcrypto.so" -o \ + -f "$1/$tmplib/libcrypto.sl" -o \ + -f "$1/$tmplib/libcrypto.dylib" \); then ac_cv_ssleay_path="$1" fi