diff options
| author | ruki <[email protected]> | 2025-03-23 18:21:48 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2025-03-23 18:21:48 +0800 |
| commit | 24ca1cece1c6fec273a65a2dff5aca8a8efef9b5 (patch) | |
| tree | d646911b6254bd2e2e7eb9741504d8a038a1499b /xmake/modules | |
| parent | 8ed7230306285162bf36aca054a30ac8258e05f7 (diff) | |
| parent | 2190152114f50bb140f3bb3572264914a32006c1 (diff) | |
Merge pull request #6236 from Doekin/dev
package(cmake): fix incorrect flag handling caused by substring matching
Diffstat (limited to 'xmake/modules')
| -rw-r--r-- | xmake/modules/package/tools/cmake.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/xmake/modules/package/tools/cmake.lua b/xmake/modules/package/tools/cmake.lua index fab2d0ff4..c0f86a95e 100644 --- a/xmake/modules/package/tools/cmake.lua +++ b/xmake/modules/package/tools/cmake.lua @@ -390,7 +390,7 @@ function _insert_configs_from_envs(configs, envs, opt) opt = opt or {} local configs_str = opt._configs_str for k, v in pairs(envs) do - if configs_str and configs_str:find(k, 1, true) then + if configs_str and configs_str:find("-D" .. k .. "=", 1, true) then -- use user custom configuration else table.insert(configs, "-D" .. k .. "=" .. v) |
