mirror of
https://github.com/open-source-parsers/jsoncpp.git
synced 2025-10-17 19:25:52 +02:00
Use non-version checked add_compile_options
Commit aebc7fa
added version checks for CMake compatibility. In reality,
only the add_compile_definitions need the check - add_compile_options
itself has been supported since 3.0. Tested and confirmed built
successfully with CMake 3.8.0.
This commit is contained in:
@@ -6,7 +6,7 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
|
||||
|
||||
#-Werror=* was introduced -after- GCC 4.1.2
|
||||
if(GNUCXX_VERSION VERSION_GREATER 4.1.2)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror=strict-aliasing")
|
||||
add_compile_options("-Werror=strict-aliasing")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
Reference in New Issue
Block a user