Fixed compile_extension.sh --release to actually enable optimization. (#7766)

pull/7790/head
Joshua Haberman 5 years ago committed by Adam Cozzette
parent 0929596575
commit 610bbd0b95
  1. 16
      php/tests/compile_extension.sh

@ -4,17 +4,17 @@ set -ex
cd $(dirname $0)
pushd ../ext/google/protobuf
phpize --clean
rm -f configure.in configure.ac
php make-preload.php
phpize
if [ "$1" = "--release" ]; then
CFLAGS="-Wall"
./configure --with-php-config=$(which php-config)
else
# To get debugging symbols in PHP itself, build PHP with:
# $ ./configure --enable-debug CFLAGS='-g -O0'
CFLAGS="-g -O0 -Wall"
./configure --with-php-config=$(which php-config) CFLAGS="-g -O0 -Wall"
fi
pushd ../ext/google/protobuf
phpize --clean
rm -f configure.in configure.ac
php make-preload.php
phpize && ./configure --with-php-config=$(which php-config) CFLAGS="$CFLAGS" && make
make
popd

Loading…
Cancel
Save