Skip to content

Commit 5f31195

Browse files
committed
renamed CMAKE_COMPILER_ID property to XMAKE_GLOBAL_COMPILER_ID to avoid potential conflicts
1 parent 6543879 commit 5f31195

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

xmake/plugins/project/cmake/cmakelists.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -817,7 +817,7 @@ function _add_target_values(cmakelists, target, name)
817817
if name:endswith("s") then
818818
name = name:sub(1, #name - 1)
819819
end
820-
cmakelists:print("if(CMAKE_COMPILER_ID STREQUAL \"MSVC\")")
820+
cmakelists:print("if(XMAKE_GLOBAL_COMPILER_ID STREQUAL \"MSVC\")")
821821
local flags_cl = _map_compflags("cl", "c", name, values)
822822
for _, flag in ipairs(flags_cl) do
823823
cmakelists:print(" target_compile_options(%s PRIVATE %s)", target:name(), flag)

0 commit comments

Comments
 (0)