File tree Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -2,5 +2,10 @@ build --//core:codspeed_mode=instrumentation
22build --compilation_mode=dbg
33build --copt=-O2
44
5+ # Treat warnings as errors
6+ build --copt=-Wall
7+ build --copt=-Wextra
8+ build --copt=-Werror
9+
510# Flip this early to avoid breaking compatibility once it becomes the default.
611build --incompatible_disallow_empty_glob
Original file line number Diff line number Diff line change @@ -8,6 +8,13 @@ project(codspeed VERSION ${CODSPEED_VERSION} LANGUAGES CXX)
88set (CMAKE_CXX_STANDARD 17)
99set (CMAKE_CXX_STANDARD_REQUIRED True )
1010
11+ # Treat warnings as errors
12+ if (CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang" )
13+ add_compile_options (-Wall -Wextra -Werror)
14+ elseif (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC" )
15+ add_compile_options (/W4 /WX)
16+ endif ()
17+
1118# Add the include directory
1219include_directories (include )
1320
You can’t perform that action at this time.
0 commit comments