jorton Wed Nov 3 09:07:09 2004 EDT Modified files: /php-src acinclude.m4 configure.in Log: Core changes to support multi-ABI platforms with libraries in /usr/lib64 rather than /usr/lib. * configure.in: Add --with-libdir flag; define PHP_LIBDIR. * acinclude.m4 (PHP_REMOVE_USR_LIB, PHP_RUNPATH_SWITCH, PHP_ADD_LIBPATH): Check for /usr/$PHP_LIBDIR rather than /usr/lib. (PHP_SETUP_OPENSSL, PHP_SETUP_ICONV): Use /path/to/$PHP_LIBDIR in place of /path/to/lib. http://cvs.php.net/diff.php/php-src/acinclude.m4?r1=1.274&r2=1.275&ty=u Index: php-src/acinclude.m4 diff -u php-src/acinclude.m4:1.274 php-src/acinclude.m4:1.275 --- php-src/acinclude.m4:1.274 Wed Nov 3 08:04:10 2004 +++ php-src/acinclude.m4 Wed Nov 3 09:07:09 2004 @@ -1,4 +1,4 @@ -dnl $Id: acinclude.m4,v 1.274 2004/11/03 13:04:10 jorton Exp $ +dnl $Id: acinclude.m4,v 1.275 2004/11/03 14:07:09 jorton Exp $ dnl dnl This file contains local autoconf functions. @@ -176,7 +176,7 @@ unset ac_new_flags for i in [$]$1; do case [$]i in - -L/usr/lib|-L/usr/lib/[)] ;; + -L/usr/$PHP_LIBDIR|-L/usr/$PHP_LIBDIR/[)] ;; *[)] ac_new_flags="[$]ac_new_flags [$]i" ;; esac done @@ -638,7 +638,7 @@ AC_MSG_CHECKING([if compiler supports -R]) AC_CACHE_VAL(php_cv_cc_dashr,[ SAVE_LIBS=$LIBS - LIBS="-R /usr/lib $LIBS" + LIBS="-R /usr/$PHP_LIBDIR $LIBS" AC_TRY_LINK([], [], php_cv_cc_dashr=yes, php_cv_cc_dashr=no) LIBS=$SAVE_LIBS]) AC_MSG_RESULT([$php_cv_cc_dashr]) @@ -648,7 +648,7 @@ AC_MSG_CHECKING([if compiler supports -Wl,-rpath,]) AC_CACHE_VAL(php_cv_cc_rpath,[ SAVE_LIBS=$LIBS - LIBS="-Wl,-rpath,/usr/lib $LIBS" + LIBS="-Wl,-rpath,/usr/$PHP_LIBDIR $LIBS" AC_TRY_LINK([], [], php_cv_cc_rpath=yes, php_cv_cc_rpath=no) LIBS=$SAVE_LIBS]) AC_MSG_RESULT([$php_cv_cc_rpath]) @@ -832,7 +832,7 @@ dnl add a library to linkpath/runpath dnl AC_DEFUN([PHP_ADD_LIBPATH],[ - if test "$1" != "/usr/lib"; then + if test "$1" != "/usr/$PHP_LIBDIR"; then PHP_EXPAND_PATH($1, ai_p) ifelse([$2],,[ _PHP_ADD_LIBPATH_GLOBAL([$ai_p]) @@ -1622,8 +1622,8 @@ if test -r $i/include/openssl/evp.h; then OPENSSL_INCDIR=$i/include fi - if test -r $i/lib/libssl.a -o -r $i/lib/libssl.$SHLIB_SUFFIX_NAME; then - OPENSSL_LIBDIR=$i/lib + if test -r $i/$PHP_LIBDIR/libssl.a -o -r $i/$PHP_LIBDIR/libssl.$SHLIB_SUFFIX_NAME; then + OPENSSL_LIBDIR=$i/$PHP_LIBDIR fi test -n "$OPENSSL_INCDIR" && test -n "$OPENSSL_LIBDIR" && break done @@ -1732,8 +1732,8 @@ AC_MSG_ERROR([Please specify the install prefix of iconv with --with-iconv=<DIR>]) fi - if test -f $ICONV_DIR/lib/lib$iconv_lib_name.a || - test -f $ICONV_DIR/lib/lib$iconv_lib_name.$SHLIB_SUFFIX_NAME + if test -f $ICONV_DIR/$PHP_LIBDIR/lib$iconv_lib_name.a || + test -f $ICONV_DIR/$PHP_LIBDIR/lib$iconv_lib_name.$SHLIB_SUFFIX_NAME then PHP_CHECK_LIBRARY($iconv_lib_name, libiconv, [ found_iconv=yes @@ -1743,10 +1743,10 @@ found_iconv=yes PHP_DEFINE(HAVE_ICONV) ], [], [ - -L$ICONV_DIR/lib + -L$ICONV_DIR/$PHP_LIBDIR ]) ], [ - -L$ICONV_DIR/lib + -L$ICONV_DIR/$PHP_LIBDIR ]) fi fi @@ -1754,7 +1754,7 @@ if test "$found_iconv" = "yes"; then if test -n "$ICONV_DIR"; then AC_DEFINE(HAVE_ICONV, 1, [ ]) - PHP_ADD_LIBRARY_WITH_PATH($iconv_lib_name, $ICONV_DIR/lib, $1) + PHP_ADD_LIBRARY_WITH_PATH($iconv_lib_name, $ICONV_DIR/$PHP_LIBDIR, $1) PHP_ADD_INCLUDE($ICONV_DIR/include) fi $2 http://cvs.php.net/diff.php/php-src/configure.in?r1=1.522&r2=1.523&ty=u Index: php-src/configure.in diff -u php-src/configure.in:1.522 php-src/configure.in:1.523 --- php-src/configure.in:1.522 Fri Oct 22 06:46:42 2004 +++ php-src/configure.in Wed Nov 3 09:07:09 2004 @@ -1,4 +1,4 @@ -dnl ## $Id: configure.in,v 1.522 2004/10/22 10:46:42 edink Exp $ -*- sh -*- +dnl ## $Id: configure.in,v 1.523 2004/11/03 14:07:09 jorton Exp $ -*- autoconf -*- dnl ## Process this file with autoconf to produce a configure script. divert(1) @@ -124,6 +124,11 @@ dnl AC_PROG_CXX dnl AC_PROG_CXXCPP +dnl Support systems with system libraries in e.g. /usr/lib64 +AC_ARG_WITH(libdir, +[ --with-libdir=NAME Look for libraries in .../NAME rather than .../lib], +[PHP_LIBDIR=$withval], [PHP_LIBDIR=lib]) + dnl check for -R, etc. switch PHP_RUNPATH_SWITCH
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php