File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -56,7 +56,9 @@ cmake \
56
56
-DWITH_SERVER=ON \
57
57
-DDISABLE_DEPRECATED=ON \
58
58
-DPYTHON_TEST_WRAPPER=" timeout -sSIGSEGV 55s" \
59
- -DCXX_EXTRA_FLAGS=" ${CLANG_WARNINGS} " ..
59
+ -DCXX_EXTRA_FLAGS=" ${CLANG_WARNINGS} " \
60
+ -DWERROR=TRUE \
61
+ ..
60
62
echo " travis_fold:end:cmake"
61
63
62
64
# ######
Original file line number Diff line number Diff line change @@ -470,7 +470,11 @@ IF (PEDANTIC)
470
470
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${_warnings} " )
471
471
ELSE (MSVC )
472
472
# add warnings via flags (not as definitions as on Mac -Wall can not be overridden per language )
473
- SET (_warnings "-Wall -Wextra -Wno-long-long -Wformat-security -Wno-strict-aliasing -Werror" )
473
+ SET (_warnings "-Wall -Wextra -Wno-long-long -Wformat-security -Wno-strict-aliasing" )
474
+ SET (WERROR FALSE CACHE BOOL "Treat build warnings as errors." )
475
+ IF (WERROR )
476
+ SET (_warnings "${_warnings} -Werror" )
477
+ ENDIF (WERROR )
474
478
SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${_warnings} " )
475
479
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${_warnings} " )
476
480
You can’t perform that action at this time.
0 commit comments