Skip to content

Commit

Permalink
CMake: fix compiler identification checks
Browse files Browse the repository at this point in the history
  • Loading branch information
FranciscoPombal authored and glassez committed May 26, 2021
1 parent 42582e2 commit 2f6abb8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmake/Modules/MacroQbtCommonConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ macro(qbt_common_config)
)
endif()

if ((CXX_COMPILER_ID STREQUAL "GNU") OR (CXX_COMPILER_ID STREQUAL "Clang") OR (CXX_COMPILER_ID STREQUAL "AppleClang"))
if ((CMAKE_CXX_COMPILER_ID STREQUAL "GNU") OR (CMAKE_CXX_COMPILER_ID STREQUAL "Clang") OR (CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang"))
target_compile_options(qbt_common_cfg INTERFACE
-Wall
-Wextra
Expand All @@ -59,7 +59,7 @@ macro(qbt_common_config)
endif()
endif()

if ((CXX_COMPILER_ID STREQUAL "Clang") OR (CXX_COMPILER_ID STREQUAL "AppleClang"))
if ((CMAKE_CXX_COMPILER_ID STREQUAL "Clang") OR (CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang"))
target_compile_options(qbt_common_cfg INTERFACE
-Wno-range-loop-analysis
)
Expand Down

0 comments on commit 2f6abb8

Please sign in to comment.