From: <al...@us...> - 2003-06-13 20:03:03
|
Update of /cvsroot/msyslog/syslog In directory sc8-pr-cvs1:/tmp/cvs-serv14182 Modified Files: configure configure.in aclocal.m4 Log Message: check for OpenSSL Index: configure =================================================================== RCS file: /cvsroot/msyslog/syslog/configure,v retrieving revision 1.101 retrieving revision 1.102 diff -u -d -r1.101 -r1.102 --- configure 13 Jun 2003 19:38:32 -0000 1.101 +++ configure 13 Jun 2003 20:02:58 -0000 1.102 @@ -2953,7 +2953,39 @@ fi -echo "$as_me:2956: checking for dlopen in -ldl" >&5 + for dir in $withval /usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr; do + ssldir="$dir" + if test -f "$dir/include/openssl/ssl.h"; then + found_ssl="yes"; + CFLAGS="$CFLAGS -I$ssldir/include/openssl -DHAVE_SSL"; + CXXFLAGS="$CXXFLAGS -I$ssldir/include/openssl -DHAVE_SSL"; + break; [...1426 lines suppressed...] { (exit 1); exit 1; }; } echo $f;; @@ -5675,7 +5708,7 @@ echo $srcdir/$f else # /dev/null tree - { { echo "$as_me:5678: error: cannot find input file: $f" >&5 + { { echo "$as_me:5711: error: cannot find input file: $f" >&5 echo "$as_me: error: cannot find input file: $f" >&2;} { (exit 1); exit 1; }; } fi;; @@ -5792,7 +5825,7 @@ rm -f $tmp/in if test x"$ac_file" != x-; then if cmp -s $ac_file $tmp/config.h 2>/dev/null; then - { echo "$as_me:5795: $ac_file is unchanged" >&5 + { echo "$as_me:5828: $ac_file is unchanged" >&5 echo "$as_me: $ac_file is unchanged" >&6;} else ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ Index: configure.in =================================================================== RCS file: /cvsroot/msyslog/syslog/configure.in,v retrieving revision 1.164 retrieving revision 1.165 diff -u -d -r1.164 -r1.165 --- configure.in 13 Jun 2003 19:38:35 -0000 1.164 +++ configure.in 13 Jun 2003 20:02:59 -0000 1.165 @@ -40,6 +40,14 @@ AC_HEADER_TIME AC_STRUCT_TM +dnl We require OpenSSL +CHECK_SSL +if test "x$HAVE_SSL" != "xyes" +then + echo "Modular Syslog requires OpenSSL"; + exit 1; +fi + dnl Checks for library functions. AC_CHECK_LIB(dl, dlopen, SYSLOGD_LIBS="$SYSLOGD_LIBS -ldl") AC_CHECK_LIB(socket, connect, SYSLOGD_LIBS="$SYSLOGD_LIBS -lsocket") Index: aclocal.m4 =================================================================== RCS file: /cvsroot/msyslog/syslog/aclocal.m4,v retrieving revision 1.31 retrieving revision 1.32 diff -u -d -r1.31 -r1.32 --- aclocal.m4 10 Mar 2001 00:26:05 -0000 1.31 +++ aclocal.m4 13 Jun 2003 20:02:59 -0000 1.32 @@ -101,3 +101,33 @@ undefine([AC_CV_NAME])dnl ]) +dnl Available from the GNU Autoconf Macro Archive at: +dnl http://www.gnu.org/software/ac-archive/htmldoc/check_ssl.html +dnl +AC_DEFUN([CHECK_SSL], +[ for dir in $withval /usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr; do + ssldir="$dir" + if test -f "$dir/include/openssl/ssl.h"; then + found_ssl="yes"; + CFLAGS="$CFLAGS -I$ssldir/include/openssl -DHAVE_SSL"; + CXXFLAGS="$CXXFLAGS -I$ssldir/include/openssl -DHAVE_SSL"; + break; + fi + if test -f "$dir/include/ssl.h"; then + found_ssl="yes"; + CFLAGS="$CFLAGS -I$ssldir/include/ -DHAVE_SSL"; + CXXFLAGS="$CXXFLAGS -I$ssldir/include/ -DHAVE_SSL"; + break + fi + done + if test x_$found_ssl != x_yes; then + AC_MSG_ERROR(Cannot find ssl libraries) + else + printf "OpenSSL found in $ssldir\n"; + LIBS="$LIBS -lssl -lcrypto"; + LDFLAGS="$LDFLAGS -L$ssldir/lib"; + HAVE_SSL=yes + fi + AC_SUBST(HAVE_SSL) +])dnl + |