mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-09 07:11:05 -06:00
Clang: Set standard flags according to frontend variant
They depend on the frontend not which compiler we're simulating. Fixes #21771.
This commit is contained in:
@@ -25,7 +25,7 @@ elseif("x${CMAKE_C_COMPILER_FRONTEND_VARIANT}" STREQUAL "xGNU")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(NOT "x${CMAKE_C_SIMULATE_ID}" STREQUAL "xMSVC")
|
||||
if("x${CMAKE_C_COMPILER_FRONTEND_VARIANT}" STREQUAL "xGNU")
|
||||
if(CMAKE_C_COMPILER_VERSION VERSION_GREATER_EQUAL 2.1)
|
||||
set(CMAKE_C90_STANDARD_COMPILE_OPTION "-std=c90")
|
||||
set(CMAKE_C90_EXTENSION_COMPILE_OPTION "-std=gnu90")
|
||||
|
||||
Reference in New Issue
Block a user