From b652368986efd6bba607855a5bfb8a679d01e085 Mon Sep 17 00:00:00 2001 From: Latias94 Date: Wed, 30 Aug 2023 01:01:07 +0800 Subject: fix: add `_escape_path` to cmd program --- xmake/plugins/project/cmake/cmakelists.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xmake/plugins/project/cmake/cmakelists.lua b/xmake/plugins/project/cmake/cmakelists.lua index d675e8f4f..f0824e1eb 100644 --- a/xmake/plugins/project/cmake/cmakelists.lua +++ b/xmake/plugins/project/cmake/cmakelists.lua @@ -917,7 +917,7 @@ function _get_command_string(cmd, outputdir) for _, v in ipairs(cmd.argv) do table.insert(argv, _translate_flag(v, outputdir)) end - local command = cmd.program .. " " .. os.args(argv) + local command = _escape_path(cmd.program) .. " " .. os.args(argv) if opt and opt.curdir then command = "${CMAKE_COMMAND} -E chdir " .. _get_relative_unix_path_to_cmake(opt.curdir, outputdir) .. " " .. command end -- cgit v1.3.1