diff options
| author | ruki <[email protected]> | 2018-11-20 22:55:35 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2018-11-20 11:33:35 +0800 |
| commit | 6902984e5c200e03f0d9f4a99d0a0801ee1acabc (patch) | |
| tree | 648e450ebfa5a66844816399fe697a61668bf80a | |
| parent | 972f51ec01b0c3b5e4af40f0071d34a1bbc0855b (diff) | |
improve to use xmake to install package
| -rw-r--r-- | xmake/modules/package/tools/autoconf.lua | 3 | ||||
| -rw-r--r-- | xmake/modules/package/tools/xmake.lua | 12 |
2 files changed, 2 insertions, 13 deletions
diff --git a/xmake/modules/package/tools/autoconf.lua b/xmake/modules/package/tools/autoconf.lua index 2958d48fa..8a47bf8de 100644 --- a/xmake/modules/package/tools/autoconf.lua +++ b/xmake/modules/package/tools/autoconf.lua @@ -46,9 +46,6 @@ function install(package, configs) table.insert(argv, value) end else - if value:find(" ", 1, true) then - value = '"' .. value .. '"' - end table.insert(argv, "--" .. name .. "=" .. value) end end diff --git a/xmake/modules/package/tools/xmake.lua b/xmake/modules/package/tools/xmake.lua index 4b625342b..2bb9ba164 100644 --- a/xmake/modules/package/tools/xmake.lua +++ b/xmake/modules/package/tools/xmake.lua @@ -34,22 +34,14 @@ function install(package, configs) for _, name in ipairs(names) do local value = get_config(name) if value ~= nil then - value = tostring(value) - if value:find(" ", 1, true) then - value = '"' .. value .. '"' - end - table.insert(argv, "--" .. name .. "=" .. value) + table.insert(argv, "--" .. name .. "=" .. tostring(value)) end end table.insert(argv, "--mode=" .. (package:debug() and "debug" or "release")) -- inherit require and option configs for name, value in pairs(table.join(package:configs() or {}, configs or {})) do - value = tostring(value) - if value:find(" ", 1, true) then - value = '"' .. value .. '"' - end - table.insert(argv, "--" .. name .. "=" .. value) + table.insert(argv, "--" .. name .. "=" .. tostring(value)) end if option.get("verbose") then table.insert(argv, "-v") |
