diff options
author | Charles Harris <charlesr.harris@gmail.com> | 2018-09-24 12:22:06 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-09-24 12:22:06 -0500 |
commit | e9d36e44ca53e6a983d87a59c23e74fdcc535d64 (patch) | |
tree | 8ece1e1b414545d33f954f45deffdc465b824544 /tools | |
parent | 5841358e7331ad4ea11cd6b5b07e3141f60cc048 (diff) | |
parent | c9f2629808ecb543efd852df54e57bb75dec9bb1 (diff) | |
download | numpy-e9d36e44ca53e6a983d87a59c23e74fdcc535d64.tar.gz |
Merge pull request #11905 from charris/c99-tests-update
TST: Start testing with "-std=c99" on travisCI.
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/travis-test.sh | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tools/travis-test.sh b/tools/travis-test.sh index d95805cee..84a57b1de 100755 --- a/tools/travis-test.sh +++ b/tools/travis-test.sh @@ -28,12 +28,16 @@ fi werrors="-Werror=declaration-after-statement -Werror=vla " werrors+="-Werror=nonnull -Werror=pointer-arith" +# build with c99 by default + setup_base() { # use default python flags but remoge sign-compare sysflags="$($PYTHON -c "from distutils import sysconfig; \ print (sysconfig.get_config_var('CFLAGS'))")" export CFLAGS="$sysflags $werrors -Wlogical-op -Wno-sign-compare" + # use c99 + export CFLAGS=$CFLAGS" -std=c99" # We used to use 'setup.py install' here, but that has the terrible # behaviour that if a copy of the package is already installed in the # install location, then the new copy just gets dropped on top of it. @@ -171,6 +175,8 @@ if [ -n "$USE_WHEEL" ] && [ $# -eq 0 ]; then $PIP install -U virtualenv # ensure some warnings are not issued export CFLAGS=$CFLAGS" -Wno-sign-compare -Wno-unused-result" + # use c99 + export CFLAGS=$CFLAGS" -std=c99" # adjust gcc flags if C coverage requested if [ -n "$RUN_COVERAGE" ]; then export NPY_DISTUTILS_APPEND_FLAGS=1 @@ -196,6 +202,8 @@ elif [ -n "$USE_SDIST" ] && [ $# -eq 0 ]; then $PYTHON -c "import fcntl; fcntl.fcntl(1, fcntl.F_SETFL, 0)" # ensure some warnings are not issued export CFLAGS=$CFLAGS" -Wno-sign-compare -Wno-unused-result" + # use c99 + export CFLAGS=$CFLAGS" -std=c99" $PYTHON setup.py sdist # Make another virtualenv to install into virtualenv --python=`which $PYTHON` venv-for-wheel |