Skip to content

Commit 2275d92

Browse files
committed
Werror: On Travis Only
The `-Werror` flag should not be shipped to users. We will enforce it manually for travis-ci testing so the (limited) set of compilers we test stays warning-free. Nevertheless, a (new) warning on a system or compiler we did not test is not necessarily fatal and would be a showstopper for new users.
1 parent f9ebe2e commit 2275d92

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

.travis.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,17 +20,17 @@ env:
2020
script:
2121
- cd $BUILD
2222
# compile libSplash and install
23-
- cmake -DCMAKE_BUILD_TYPE=Debug -DTOOLS_MPI=$SPLASHMPI $SRC
23+
- CXXFLAGS="-Werror" cmake -DCMAKE_BUILD_TYPE=Debug -DTOOLS_MPI=$SPLASHMPI $SRC
2424
- make package
2525
- sudo dpkg -i libsplash*.deb
2626
- ls -hal /usr/share/pyshared/
2727
- rm -rf $BUILD/*
2828
# compile examples/
29-
- cmake -DCMAKE_BUILD_TYPE=Debug -DWITH_MPI=$SPLASHMPI $SRC/examples
29+
- CXXFLAGS="-Werror" cmake -DCMAKE_BUILD_TYPE=Debug -DWITH_MPI=$SPLASHMPI $SRC/examples
3030
- make
3131
- rm -rf $BUILD/*
3232
# compile and run tests/
33-
- cmake -DCMAKE_BUILD_TYPE=Debug -DWITH_MPI=$SPLASHMPI $SRC/tests
33+
- CXXFLAGS="-Werror" cmake -DCMAKE_BUILD_TYPE=Debug -DWITH_MPI=$SPLASHMPI $SRC/tests
3434
- make
3535
# run tests
3636
- $SRC/tests/run_tests $BUILD

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ UNSET(HDF5_HAS_SHARED_POS)
8787

8888
#-------------------------------------------------------------------------------
8989

90-
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Werror -Wextra -Woverloaded-virtual")
90+
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Woverloaded-virtual")
9191

9292
# options
9393
OPTION(DEBUG_VERBOSE "Enable verbose HDF5 debug output" OFF)

0 commit comments

Comments
 (0)