diff options
-rw-r--r-- | CMakeLists.txt | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 749bfb75ac..d3764f4a99 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -96,7 +96,7 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Darwin") # Work around some old, broken detection by CMake for knowing when to use the # isystem flag. Apple's compilers have supported this for quite some time # now. - if(CMAKE_COMPILER_IS_GNUCC) + if(CMAKE_C_COMPILER_ID MATCHES "GNU") set(CMAKE_INCLUDE_SYSTEM_FLAG_C "-isystem ") endif() endif() @@ -170,7 +170,7 @@ if(CMAKE_C_FLAGS_RELEASE MATCHES "-O3") string(REPLACE "-O3" "-O2" CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE}") endif() -if(CMAKE_COMPILER_IS_GNUCC) +if(CMAKE_C_COMPILER_ID MATCHES "GNU") check_c_compiler_flag(-Og HAS_OG_FLAG) else() set(HAS_OG_FLAG 0) |