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)
|
||||
============================
|
||||
|
||||
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
|
||||
Fix memory leak in SWIG's parser (based on patch from Russell
|
||||
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".
|
||||
if test x"${PHP4BIN}" = xno -o x"${with_alllang}" = xno ; then
|
||||
AC_MSG_NOTICE([Disabling PHP])
|
||||
PHP4=
|
||||
AC_MSG_NOTICE([Disabling PHP])
|
||||
PHP4=
|
||||
else
|
||||
|
||||
if test "x$PHP4BIN" = xyes; then
|
||||
if test "x$PHP4BIN" = xyes; then
|
||||
AC_CHECK_PROGS(PHP4, php5 php php4)
|
||||
else
|
||||
PHP4="$PHP4BIN"
|
||||
fi
|
||||
else
|
||||
PHP4=$PHP4BIN
|
||||
fi
|
||||
|
||||
AC_MSG_CHECKING(for PHP header files)
|
||||
dnl /usr/bin/php5 -> /usr/bin/php-config5
|
||||
PHP4CONFIG=`echo "$PHP4"|sed 's/\([[45]]\?\)$/-config\1/'`
|
||||
PHP4INC="`$PHP4CONFIG --includes 2>/dev/null`"
|
||||
if test "$PHP4INC"; then
|
||||
AC_MSG_RESULT($PHP4INC)
|
||||
else
|
||||
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"
|
||||
for i in $dirs; do
|
||||
echo $i
|
||||
if test -r $i/php_config.h -o -r $i/php_version.h; then
|
||||
AC_MSG_RESULT($i)
|
||||
PHP4EXT="$i"
|
||||
PHP4INC="-I$PHP4EXT -I$PHP4EXT/Zend -I$PHP4EXT/main -I$PHP4EXT/TSRM"
|
||||
break
|
||||
fi
|
||||
done
|
||||
fi
|
||||
if test -z "$PHP4INC"; then
|
||||
AC_MSG_RESULT(not found)
|
||||
fi
|
||||
AC_MSG_CHECKING(for PHP header files)
|
||||
dnl /usr/bin/php5 -> /usr/bin/php-config5
|
||||
case $PHP4 in
|
||||
*[[45]])
|
||||
PHP4CONFIG=`echo "$PHP4"|sed 's/\([[45]]\)$/-config\1/'` ;;
|
||||
*)
|
||||
PHP4CONFIG=$PHP4-config ;;
|
||||
esac
|
||||
PHP4INC=`$PHP4CONFIG --includes 2>/dev/null`
|
||||
if test -n "$PHP4INC"; then
|
||||
AC_MSG_RESULT($PHP4INC)
|
||||
else
|
||||
AC_MSG_RESULT(not found)
|
||||
fi
|
||||
|
||||
fi
|
||||
AC_SUBST(PHP4)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue