Fix nonportable sed usage which failed on Mac OS X (and probably
other platforms). Fixes SF#1903612. git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10311 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
f881f98daf
commit
39ad0f01f6
2 changed files with 24 additions and 27 deletions
|
|
@ -1,6 +1,10 @@
|
||||||
Version 1.3.35 (in progress)
|
Version 1.3.35 (in progress)
|
||||||
============================
|
============================
|
||||||
|
|
||||||
|
03/17/2008: olly
|
||||||
|
Fix nonportable sed usage which failed on Mac OS X (and probably
|
||||||
|
other platforms). Fixes SF#1903612.
|
||||||
|
|
||||||
03/17/2008: olly
|
03/17/2008: olly
|
||||||
Fix memory leak in SWIG's parser (based on patch from Russell
|
Fix memory leak in SWIG's parser (based on patch from Russell
|
||||||
Bryant in SF#1914023).`
|
Bryant in SF#1914023).`
|
||||||
|
|
|
||||||
47
configure.in
47
configure.in
|
|
@ -1231,37 +1231,30 @@ AS_HELP_STRING([--with-php4=path], [Set location of PHP executable]),[ PHP4BIN="
|
||||||
|
|
||||||
# First, check for "--without-php4" or "--with-php4=no".
|
# First, check for "--without-php4" or "--with-php4=no".
|
||||||
if test x"${PHP4BIN}" = xno -o x"${with_alllang}" = xno ; then
|
if test x"${PHP4BIN}" = xno -o x"${with_alllang}" = xno ; then
|
||||||
AC_MSG_NOTICE([Disabling PHP])
|
AC_MSG_NOTICE([Disabling PHP])
|
||||||
PHP4=
|
PHP4=
|
||||||
else
|
else
|
||||||
|
|
||||||
if test "x$PHP4BIN" = xyes; then
|
if test "x$PHP4BIN" = xyes; then
|
||||||
AC_CHECK_PROGS(PHP4, php5 php php4)
|
AC_CHECK_PROGS(PHP4, php5 php php4)
|
||||||
else
|
else
|
||||||
PHP4="$PHP4BIN"
|
PHP4=$PHP4BIN
|
||||||
fi
|
fi
|
||||||
|
|
||||||
AC_MSG_CHECKING(for PHP header files)
|
AC_MSG_CHECKING(for PHP header files)
|
||||||
dnl /usr/bin/php5 -> /usr/bin/php-config5
|
dnl /usr/bin/php5 -> /usr/bin/php-config5
|
||||||
PHP4CONFIG=`echo "$PHP4"|sed 's/\([[45]]\?\)$/-config\1/'`
|
case $PHP4 in
|
||||||
PHP4INC="`$PHP4CONFIG --includes 2>/dev/null`"
|
*[[45]])
|
||||||
if test "$PHP4INC"; then
|
PHP4CONFIG=`echo "$PHP4"|sed 's/\([[45]]\)$/-config\1/'` ;;
|
||||||
AC_MSG_RESULT($PHP4INC)
|
*)
|
||||||
else
|
PHP4CONFIG=$PHP4-config ;;
|
||||||
dirs="/usr/include/php /usr/local/include/php /usr/include/php5 /usr/local/include/php5 /usr/include/php4 /usr/local/include/php4 /usr/local/apache/php"
|
esac
|
||||||
for i in $dirs; do
|
PHP4INC=`$PHP4CONFIG --includes 2>/dev/null`
|
||||||
echo $i
|
if test -n "$PHP4INC"; then
|
||||||
if test -r $i/php_config.h -o -r $i/php_version.h; then
|
AC_MSG_RESULT($PHP4INC)
|
||||||
AC_MSG_RESULT($i)
|
else
|
||||||
PHP4EXT="$i"
|
AC_MSG_RESULT(not found)
|
||||||
PHP4INC="-I$PHP4EXT -I$PHP4EXT/Zend -I$PHP4EXT/main -I$PHP4EXT/TSRM"
|
fi
|
||||||
break
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
if test -z "$PHP4INC"; then
|
|
||||||
AC_MSG_RESULT(not found)
|
|
||||||
fi
|
|
||||||
|
|
||||||
fi
|
fi
|
||||||
AC_SUBST(PHP4)
|
AC_SUBST(PHP4)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue