summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--acinclude.m456
-rw-r--r--configure.in96
-rw-r--r--ext/dba/config.m462
3 files changed, 104 insertions, 110 deletions
diff --git a/acinclude.m4 b/acinclude.m4
index 51960ef2c5..7ce275c418 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -5,7 +5,7 @@ dnl This file contains local autoconf functions.
sinclude(dynlib.m4)
AC_DEFUN(PHP_REMOVE_USR_LIB,[
- ac_new_flags=""
+ unset ac_new_flags
for i in [$]$1; do
case [$]i in
-L/usr/lib|-L/usr/lib/) ;;
@@ -32,7 +32,7 @@ AC_DEFUN(PHP_SETUP_OPENSSL,[
fi
old_CPPFLAGS=$CPPFLAGS
- CPPFLAGS="-I$OPENSSL_INC"
+ CPPFLAGS=-I$OPENSSL_INC
AC_MSG_CHECKING(for OpenSSL version)
AC_EGREP_CPP(yes,[
#include <openssl/opensslv.h>
@@ -162,7 +162,7 @@ AC_DEFUN(PHP_SHLIB_SUFFIX_NAME,[
])
AC_DEFUN(PHP_DEBUG_MACRO,[
- DEBUG_LOG="$1"
+ DEBUG_LOG=$1
cat >$1 <<X
CONFIGURE: $CONFIGURE_COMMAND
CC: $CC
@@ -225,7 +225,7 @@ dnl Stores the location of libgcc in libgcc_libpath
dnl
AC_DEFUN(PHP_LIBGCC_LIBPATH,[
changequote({,})
- libgcc_libpath="`$1 --print-libgcc-file-name|sed 's%/*[^/][^/]*$%%'`"
+ libgcc_libpath=`$1 --print-libgcc-file-name|sed 's%/*[^/][^/]*$%%'`
changequote([,])
])
@@ -242,11 +242,11 @@ shared)
$1=yes
;;
no)
- ext_output="no"
+ ext_output=no
ext_shared=no
;;
*)
- ext_output="yes"
+ ext_output=yes
ext_shared=no
;;
esac
@@ -410,26 +410,26 @@ AC_DEFUN(PHP_RUNPATH_SWITCH,[
dnl check for -R, etc. switch
AC_MSG_CHECKING(if compiler supports -R)
AC_CACHE_VAL(php_cv_cc_dashr,[
- SAVE_LIBS="${LIBS}"
- LIBS="-R /usr/lib ${LIBS}"
+ SAVE_LIBS=$LIBS
+ LIBS="-R /usr/lib $LIBS"
AC_TRY_LINK([], [], php_cv_cc_dashr=yes, php_cv_cc_dashr=no)
- LIBS="${SAVE_LIBS}"])
+ LIBS=$SAVE_LIBS])
AC_MSG_RESULT($php_cv_cc_dashr)
if test $php_cv_cc_dashr = "yes"; then
- ld_runpath_switch="-R"
+ ld_runpath_switch=-R
else
AC_MSG_CHECKING([if compiler supports -Wl,-rpath,])
AC_CACHE_VAL(php_cv_cc_rpath,[
- SAVE_LIBS="${LIBS}"
- LIBS="-Wl,-rpath,/usr/lib ${LIBS}"
+ SAVE_LIBS=$LIBS
+ LIBS="-Wl,-rpath,/usr/lib $LIBS"
AC_TRY_LINK([], [], php_cv_cc_rpath=yes, php_cv_cc_rpath=no)
- LIBS="${SAVE_LIBS}"])
+ LIBS=$SAVE_LIBS])
AC_MSG_RESULT($php_cv_cc_rpath)
if test $php_cv_cc_rpath = "yes"; then
- ld_runpath_switch="-Wl,-rpath,"
+ ld_runpath_switch=-Wl,-rpath,
else
dnl something innocuous
- ld_runpath_switch="-L"
+ ld_runpath_switch=-L
fi
fi
])
@@ -476,7 +476,7 @@ dnl set the path of the file which contains the symbol export list
dnl
AC_DEFUN(PHP_SET_SYM_FILE,
[
- PHP_SYM_FILE="$1"
+ PHP_SYM_FILE=$1
])
dnl
@@ -541,7 +541,7 @@ dnl expands path to an absolute path and assigns it to variable
dnl
AC_DEFUN(PHP_EXPAND_PATH,[
if test -z "$1" || echo "$1" | grep '^/' >/dev/null ; then
- $2="$1"
+ $2=$1
else
changequote({,})
ep_dir="`echo $1|sed 's%/*[^/][^/]*/*$%%'`"
@@ -579,11 +579,11 @@ dnl
AC_DEFUN(PHP_BUILD_RPATH,[
if test "$PHP_RPATH" = "yes" && test -n "$PHP_RPATHS"; then
OLD_RPATHS="$PHP_RPATHS"
- PHP_RPATHS=""
+ unset PHP_RPATHS
for i in $OLD_RPATHS; do
PHP_LDFLAGS="$PHP_LDFLAGS -L$i"
PHP_RPATHS="$PHP_RPATHS -R $i"
- NATIVE_RPATHS="$NATIVE_RPATHS ${ld_runpath_switch}$i"
+ NATIVE_RPATHS="$NATIVE_RPATHS $ld_runpath_switch$i"
done
fi
])
@@ -684,7 +684,7 @@ dnl Check for cc option
dnl
AC_DEFUN(PHP_CHECK_CC_OPTION,[
echo "main(){return 0;}" > conftest.$ac_ext
- opt="$1"
+ opt=$1
changequote({,})
var=`echo $opt|sed 's/[^a-zA-Z0-9]/_/g'`
changequote([,])
@@ -772,12 +772,12 @@ AC_DEFUN(PHP_EXTENSION,[
if test -d "$abs_srcdir/ext/$1"; then
dnl ---------------------------------------------- Internal Module
- ext_builddir="ext/$1"
- ext_srcdir="$abs_srcdir/ext/$1"
+ ext_builddir=ext/$1
+ ext_srcdir=$abs_srcdir/ext/$1
else
dnl ---------------------------------------------- External Module
- ext_builddir="."
- ext_srcdir="$abs_srcdir"
+ ext_builddir=.
+ ext_srcdir=$abs_srcdir
fi
if test "$2" != "shared" && test "$2" != "yes"; then
@@ -809,7 +809,7 @@ dnl choose dynamic extensions, and after the gcc test.
dnl
AC_DEFUN(PHP_SOLARIS_PIC_WEIRDNESS,[
AC_MSG_CHECKING(whether -fPIC is required)
- if test "$EXT_SHARED" != ""; then
+ if test -n "$EXT_SHARED"; then
os=`uname -sr 2>/dev/null`
case "$os" in
"SunOS 5.6"|"SunOS 5.7")
@@ -939,11 +939,11 @@ int main(void) {
return (unsigned char)'A' != (unsigned char)0xC1;
}
],[
- ac_cv_ebcdic="yes"
+ ac_cv_ebcdic=yes
],[
- ac_cv_ebcdic="no"
+ ac_cv_ebcdic=no
],[
- ac_cv_ebcdic="no"
+ ac_cv_ebcdic=no
])])
if test "$ac_cv_ebcdic" = "yes"; then
AC_DEFINE(CHARSET_EBCDIC,1, [Define if system uses EBCDIC])
diff --git a/configure.in b/configure.in
index ea57cbd18b..349153b2b2 100644
--- a/configure.in
+++ b/configure.in
@@ -23,7 +23,7 @@ for arg in $0 "$@"; do
CONFIGURE_COMMAND="$CONFIGURE_COMMAND '$arg'"
done
-php_shtool="$srcdir/build/shtool"
+php_shtool=$srcdir/build/shtool
T_MD=`$php_shtool echo -n -e %B`
T_ME=`$php_shtool echo -n -e %b`
@@ -172,26 +172,26 @@ PHP_MISSING_TIME_R_DECL
dnl check for -R, etc. switch
AC_MSG_CHECKING(whether compiler supports -R)
AC_CACHE_VAL(php_cv_cc_dashr,[
- SAVE_LIBS="${LIBS}"
- LIBS="-R /usr/lib ${LIBS}"
+ SAVE_LIBS=$LIBS
+ LIBS="-R /usr/lib $LIBS"
AC_TRY_LINK([], [], php_cv_cc_dashr=yes, php_cv_cc_dashr=no)
- LIBS="${SAVE_LIBS}"])
+ LIBS=$SAVE_LIBS])
AC_MSG_RESULT($php_cv_cc_dashr)
if test $php_cv_cc_dashr = "yes"; then
- ld_runpath_switch="-R"
+ ld_runpath_switch=-R
else
AC_MSG_CHECKING([whether compiler supports -Wl,-rpath,])
AC_CACHE_VAL(php_cv_cc_rpath,[
- SAVE_LIBS="${LIBS}"
- LIBS="-Wl,-rpath,/usr/lib ${LIBS}"
+ SAVE_LIBS=$LIBS
+ LIBS="-Wl,-rpath,/usr/lib $LIBS"
AC_TRY_LINK([], [], php_cv_cc_rpath=yes, php_cv_cc_rpath=no)
- LIBS="${SAVE_LIBS}"])
+ LIBS=$SAVE_LIBS])
AC_MSG_RESULT($php_cv_cc_rpath)
if test $php_cv_cc_rpath = "yes"; then
- ld_runpath_switch="-Wl,-rpath,"
+ ld_runpath_switch=-Wl,-rpath,
else
dnl something innocuous
- ld_runpath_switch="-L"
+ ld_runpath_switch=-L
fi
fi
@@ -476,34 +476,34 @@ PHP_ARG_WITH(config-file-path,[path to configuration file],
Sets the path in which to look for php.ini,
defaults to PREFIX/lib], DEFAULT)
-if test "x$PHP_CONFIG_FILE_PATH" = "xDEFAULT"; then
+if test "$PHP_CONFIG_FILE_PATH" = "DEFAULT"; then
case $PHP_LAYOUT in
GNU)
- PHP_CONFIG_FILE_PATH="$sysconfdir"
+ PHP_CONFIG_FILE_PATH=$sysconfdir
oldstyleextdir=no;;
*)
- PHP_CONFIG_FILE_PATH="$libdir"
+ PHP_CONFIG_FILE_PATH=$libdir
oldstyleextdir=yes;;
esac
fi
# compatibility
if test "x$with_pear" = "x" -a "x$enable_pear" = "xno"; then
- with_pear="no"
+ with_pear=no
fi
PHP_ARG_WITH(pear, [whether to install PEAR, and where],
[ --with-pear=DIR Install PEAR in DIR (default PREFIX/lib/php)
--without-pear Do not install PEAR], DEFAULT)
-if test "x$PHP_PEAR" != "xno"; then
+if test "$PHP_PEAR" != "no"; then
PEAR_DIR=pear
fi
-if test "x$PHP_PEAR" = "xDEFAULT"; then
+if test "$PHP_PEAR" = "DEFAULT"; then
case $PHP_LAYOUT in
- GNU) PEAR_INSTALLDIR="$datadir/pear";;
- *) PEAR_INSTALLDIR="$libdir/php";;
+ GNU) PEAR_INSTALLDIR=$datadir/pear;;
+ *) PEAR_INSTALLDIR=$libdir/php;;
esac
fi
@@ -698,8 +698,7 @@ if test "$abs_srcdir" != "$abs_builddir"; then
fi
EXTRA_LIBS="$EXTRA_LIBS $DLIBS $LIBS"
-LIBS=""
-LDFLAGS=""
+unset LIBS LDFLAGS
PHP_CONFIGURE_PART(Configuring TSRM)
TSRM_BASIC_CHECKS
@@ -708,31 +707,30 @@ if test "$PHP_THREAD_SAFETY" = "yes"; then
fi
EXTRA_LDFLAGS="$EXTRA_LDFLAGS $LDFLAGS"
EXTRA_LIBS="$EXTRA_LIBS $LIBS"
-LDFLAGS=""
-LIBS=""
+unset LIBS LDFLAGS
-test "$prefix" = "NONE" && prefix="/usr/local"
+test "$prefix" = "NONE" && prefix=/usr/local
test "$exec_prefix" = "NONE" && exec_prefix='${prefix}'
case $libdir in
'${exec_prefix}/lib')
- libdir="$libdir/php"
+ libdir=$libdir/php
;;
esac
case $datadir in
'${prefix}/share')
- datadir="$datadir/php"
+ datadir=$datadir/php
;;
*) ;;
esac
-phplibdir="`pwd`/modules"
+phplibdir=`pwd`/modules
$php_shtool mkdir -p $phplibdir
-phptempdir="`pwd`/libs"
+phptempdir=`pwd`/libs
-old_exec_prefix="$exec_prefix"
-old_libdir="$libdir"
-old_datadir="$datadir"
+old_exec_prefix=$exec_prefix
+old_libdir=$libdir
+old_datadir=$datadir
exec_prefix=`eval echo $exec_prefix`
libdir=`eval echo $libdir`
datadir=`eval echo $datadir`
@@ -741,30 +739,30 @@ dnl Build extension directory path
ZEND_MODULE_API_NO=`egrep '#define ZEND_MODULE_API_NO ' $srcdir/Zend/zend_modules.h|sed 's/#define ZEND_MODULE_API_NO //'`
-if test "x$EXTENSION_DIR" = "x"; then
- extbasedir="$ZEND_MODULE_API_NO"
+if test -z "$EXTENSION_DIR"; then
+ extbasedir=$ZEND_MODULE_API_NO
if test "$oldstyleextdir" = "yes"; then
if test "$PHP_DEBUG" = "1"; then
- part1="debug"
+ part1=debug
else
- part1="no-debug"
+ part1=no-debug
fi
if test "$enable_experimental_zts" = "yes"; then
- part2="zts"
+ part2=zts
else
- part2="non-zts"
+ part2=non-zts
fi
- extbasedir="$part1-$part2-$extbasedir"
- EXTENSION_DIR="$libdir/extensions/$extbasedir"
+ extbasedir=$part1-$part2-$extbasedir
+ EXTENSION_DIR=$libdir/extensions/$extbasedir
else
if test "$enable_experimental_zts" = "yes"; then
- extbasedir="${extbasedir}-zts"
+ extbasedir=$extbasedir-zts
fi
if test "$PHP_DEBUG" = "1"; then
- extbasedir="${extbasedir}-debug"
+ extbasedir=$extbasedir-debug
fi
- EXTENSION_DIR="$libdir/$extbasedir"
+ EXTENSION_DIR=$libdir/$extbasedir
fi
fi
@@ -773,15 +771,15 @@ EXPANDED_PEAR_INSTALLDIR=`eval echo $PEAR_INSTALLDIR`
EXPANDED_EXTENSION_DIR=`eval echo $EXTENSION_DIR`
EXPANDED_LOCALSTATEDIR=`eval echo $localstatedir`
EXPANDED_BINDIR=`eval echo $bindir`
-EXPANDED_LIBDIR="$libdir"
+EXPANDED_LIBDIR=$libdir
EXPANDED_SYSCONFDIR=`eval echo $sysconfdir`
-EXPANDED_DATADIR="$datadir"
+EXPANDED_DATADIR=$datadir
EXPANDED_PHP_CONFIG_FILE_PATH=`eval echo "$PHP_CONFIG_FILE_PATH"`
-INCLUDE_PATH=".:${EXPANDED_PEAR_INSTALLDIR}"
+INCLUDE_PATH=.:$EXPANDED_PEAR_INSTALLDIR
-exec_prefix="$old_exec_prefix"
-libdir="$old_libdir"
-datadir="$old_datadir"
+exec_prefix=$old_exec_prefix
+libdir=$old_libdir
+datadir=$old_datadir
AC_SUBST(INCLUDE_PATH)
AC_SUBST(EXPANDED_PEAR_INSTALLDIR)
@@ -864,7 +862,7 @@ PHP_SUBST_OLD(YACC)
PHP_CONFIGURE_PART(Configuring libtool)
-old_CC="$CC"
+old_CC=$CC
if test "$PHP_THREAD_SAFETY" = "yes" && test -n "$ac_cv_pthreads_cflags"; then
CXXFLAGS="$CXXFLAGS $ac_cv_pthreads_cflags"
@@ -904,7 +902,7 @@ else
fi
fi
-CC="$old_CC"
+CC=$old_CC
changequote({,})
if test "$PHP_PIC" = "no"; then
diff --git a/ext/dba/config.m4 b/ext/dba/config.m4
index 5afb97bb9b..c48cf97c96 100644
--- a/ext/dba/config.m4
+++ b/ext/dba/config.m4
@@ -13,8 +13,8 @@ AC_DEFUN(PHP_TEMP_LDFLAGS,[
dnl Assign INCLUDE/LFLAGS from PREFIX
AC_DEFUN(PHP_DBA_STD_ASSIGN,[
if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
- THIS_INCLUDE="$THIS_PREFIX/include"
- THIS_LFLAGS="$THIS_PREFIX/lib"
+ THIS_INCLUDE=$THIS_PREFIX/include
+ THIS_LFLAGS=$THIS_PREFIX/lib
fi
])
@@ -33,11 +33,7 @@ dnl Attach THIS_x to DBA_x
AC_DEFUN(PHP_DBA_STD_ATTACH,[
PHP_ADD_INCLUDE($THIS_INCLUDE)
PHP_ADD_LIBRARY_WITH_PATH($THIS_LIBS, $THIS_LFLAGS, DBA_SHARED_LIBADD)
-
- THIS_INCLUDE=""
- THIS_LIBS=""
- THIS_LFLAGS=""
- THIS_PREFIX=""
+ unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
])
dnl Print the result message
@@ -48,7 +44,7 @@ AC_DEFUN(AC_DBA_STD_RESULT,[
else
AC_MSG_RESULT(no)
fi
- THIS_RESULT=""
+ unset THIS_RESULT
])
PHP_ARG_ENABLE(dba,whether to enable DBA,
@@ -65,7 +61,7 @@ AC_ARG_WITH(gdbm,
unset ac_cv_lib_gdbm_gdbm_open
PHP_TEMP_LDFLAGS(-L$THIS_PREFIX/lib,[
- AC_CHECK_LIB(gdbm, gdbm_open, [AC_DEFINE(DBA_GDBM, 1, [ ]) THIS_LIBS="gdbm"])
+ AC_CHECK_LIB(gdbm, gdbm_open, [AC_DEFINE(DBA_GDBM, 1, [ ]) THIS_LIBS=gdbm])
])
PHP_DBA_STD_ASSIGN
@@ -81,11 +77,11 @@ AC_ARG_WITH(ndbm,
if test "$withval" != "no"; then
for i in /usr/local /usr $withval; do
if test -f "$i/include/db1/ndbm.h" ; then
- THIS_PREFIX="$i"
- NDBM_EXTRA="db1/ndbm.h"
+ THIS_PREFIX=$i
+ NDBM_EXTRA=db1/ndbm.h
elif test -f "$i/include/ndbm.h" ; then
- THIS_PREFIX="$i"
- NDBM_EXTRA="ndbm.h"
+ THIS_PREFIX=$i
+ NDBM_EXTRA=ndbm.h
fi
done
@@ -95,7 +91,7 @@ AC_ARG_WITH(ndbm,
for LIB in db1 ndbm c; do
PHP_TEMP_LDFLAGS(-L$THIS_PREFIX/lib,[
- AC_CHECK_LIB($LIB, dbm_open, [AC_DEFINE(DBA_NDBM,1, [ ]) THIS_LIBS="$LIB"])
+ AC_CHECK_LIB($LIB, dbm_open, [AC_DEFINE(DBA_NDBM,1, [ ]) THIS_LIBS=$LIB])
])
done
@@ -112,26 +108,26 @@ AC_ARG_WITH(db2,
if test "$withval" != "no"; then
for i in /usr/local /usr /usr/BerkeleyDB $withval; do
if test -f "$i/db2/db.h"; then
- THIS_PREFIX="$i"
- DB2_EXTRA="db2"
+ THIS_PREFIX=$i
+ DB2_EXTRA=db2
elif test -f "$i/include/db2/db.h"; then
- THIS_PREFIX="$i"
- DB2_EXTRA="db2/db.h"
+ THIS_PREFIX=$i
+ DB2_EXTRA=db2/db.h
elif test -f "$i/include/db/db2.h"; then
- THIS_PREFIX="$i"
- DB2_EXTRA="db/db2.h"
+ THIS_PREFIX=$i
+ DB2_EXTRA=db/db2.h
elif test -f "$i/include/db2.h"; then
- THIS_PREFIX="$i"
- DB2_EXTRA="db2.h"
+ THIS_PREFIX=$i
+ DB2_EXTRA=db2.h
elif test -f "$i/include/db.h" ; then
- THIS_PREFIX="$i"
- DB2_EXTRA="db.h"
+ THIS_PREFIX=$i
+ DB2_EXTRA=db.h
fi
done
if test "$DB2_EXTRA" = "db2" ; then
DBA_INCLUDE="$DBA_INCLUDE -I$THIS_PREFIX/db2"
- DB2_EXTRA="db.h"
+ DB2_EXTRA=db.h
fi
if test -n "$DB2_EXTRA"; then
@@ -140,7 +136,7 @@ AC_ARG_WITH(db2,
for LIB in db db2 c; do
PHP_TEMP_LDFLAGS(-L$THIS_PREFIX/lib,[
- AC_CHECK_LIB($LIB, db_appinit, [AC_DEFINE(DBA_DB2,1,[ ]) THIS_LIBS="$LIB"])
+ AC_CHECK_LIB($LIB, db_appinit, [AC_DEFINE(DBA_DB2,1,[ ]) THIS_LIBS=$LIB])
])
done
@@ -157,8 +153,8 @@ AC_ARG_WITH(db3,
if test "$withval" != "no"; then
for i in /usr/local /usr /usr/local/BerkeleyDB.3.0 $withval; do
if test -f "$i/include/db.h" ; then
- THIS_PREFIX="$i"
- DB3_EXTRA="db.h"
+ THIS_PREFIX=$i
+ DB3_EXTRA=db.h
fi
done
@@ -168,7 +164,7 @@ AC_ARG_WITH(db3,
for LIB in db db-3; do
PHP_TEMP_LDFLAGS(-L$THIS_PREFIX/lib,[
- AC_CHECK_LIB($LIB, db_create, [AC_DEFINE(DBA_DB3,1,[ ]) THIS_LIBS="$LIB"])
+ AC_CHECK_LIB($LIB, db_create, [AC_DEFINE(DBA_DB3,1,[ ]) THIS_LIBS=$LIB])
])
done
@@ -185,13 +181,13 @@ AC_ARG_WITH(dbm,
if test "$withval" != "no"; then
for i in /usr/local /usr $withval; do
if test -f "$i/include/dbm.h" ; then
- THIS_PREFIX="$i"
+ THIS_PREFIX=$i
fi
done
for LIB in db1 dbm c; do
PHP_TEMP_LDFLAGS(-L$THIS_PREFIX/lib,[
- AC_CHECK_LIB($LIB, dbminit, [AC_DEFINE(DBA_DBM,1,[ ]) THIS_LIBS="$LIB"])
+ AC_CHECK_LIB($LIB, dbminit, [AC_DEFINE(DBA_DBM,1,[ ]) THIS_LIBS=$LIB])
])
done
@@ -208,13 +204,13 @@ AC_ARG_WITH(cdb,
if test "$withval" != "no"; then
for i in /usr/local /usr $withval; do
if test -f "$i/include/cdb.h" ; then
- THIS_PREFIX="$i"
+ THIS_PREFIX=$i
fi
done
for LIB in cdb c; do
PHP_TEMP_LDFLAGS(-L$THIS_PREFIX/lib,[
- AC_CHECK_LIB($LIB, cdb_bread, [AC_DEFINE(DBA_CDB,1,[ ]) THIS_LIBS="$LIB"])
+ AC_CHECK_LIB($LIB, cdb_bread, [AC_DEFINE(DBA_CDB,1,[ ]) THIS_LIBS=$LIB])
])
done