You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
13 lines
372 B
13 lines
372 B
enable_language(C)
|
|
|
|
cmake_policy(GET CMP0092 cmp0092)
|
|
if(cmp0092 STREQUAL "NEW")
|
|
if("${CMAKE_C_FLAGS}" MATCHES "([/-]W[0-9])")
|
|
message(SEND_ERROR "CMAKE_C_FLAGS has '${CMAKE_MATCH_1}' under NEW behavior")
|
|
endif()
|
|
else()
|
|
if(NOT " ${CMAKE_C_FLAGS} " MATCHES " /W3 ")
|
|
message(SEND_ERROR "CMAKE_C_FLAGS does not have '/W3' under OLD behavior")
|
|
endif()
|
|
endif()
|