Files
allwpilib/cmake/modules/CompileWarnings.cmake
Peter Johnson 372ca4f456 cmake: Enable googletest unit tests (#1720)
Also don't inherit compile warnings from wpiutil

There's not a good way to disable inherited compiler flags.
2019-06-23 12:44:28 -07:00

8 lines
278 B
CMake

macro(wpilib_target_warnings target)
if(NOT MSVC)
target_compile_options(${target} PRIVATE -Wall -pedantic -Wextra -Werror -Wno-unused-parameter)
else()
target_compile_options(${target} PRIVATE /wd4244 /wd4267 /wd4146 /WX /wd4996)
endif()
endmacro()