Skip to content

Commit

Permalink
Update cmakelists.lua
Browse files Browse the repository at this point in the history
  • Loading branch information
waruqi authored Dec 19, 2024
1 parent 58c7745 commit 11a26d2
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions xmake/plugins/project/cmake/cmakelists.lua
Original file line number Diff line number Diff line change
Expand Up @@ -104,12 +104,9 @@ end
-- escape path in flag
-- @see https://github.com/xmake-io/xmake/issues/3161
function _escape_path_in_flag(target, flag)

if is_host("windows") and (target:has_tool("cc", "cl")
or target:is_plat("android") -- e.g. -isystem\ c:/path/to/ndk/28.0.12674087/
) then
-- e.g. /ManifestInput:xx, /def:xxx
if flag:find(":", 1, true) then
if is_host("windows") then
-- e.g. /ManifestInput:..\..\, /def:xxx, -isystem c:\xxx, -Ic:\..
if flag:find("\\", 1, true) then
flag = _escape_path(flag)
end
end
Expand Down

0 comments on commit 11a26d2

Please sign in to comment.