Skip to content

Commit 68076a5

Browse files
committed
revert cmake default flags #6781
1 parent ec46b85 commit 68076a5

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

xmake/modules/package/tools/cmake.lua

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -942,9 +942,6 @@ function _get_configs(package, configs, opt)
942942
configs = configs or {}
943943
opt._configs_str = string.serialize(configs, {indent = false, strip = true})
944944

945-
-- we need to get the default flags first to avoid being overwritten.
946-
-- @see https://github.com/xmake-io/xmake/issues/6781
947-
local envs = _get_envs_for_default_flags(package, configs, opt)
948945

949946
_get_configs_for_install(package, configs, opt)
950947
_get_configs_for_generator(package, configs, opt)
@@ -980,6 +977,7 @@ function _get_configs(package, configs, opt)
980977
table.insert(configs, "-DCMAKE_POLICY_VERSION_MINIMUM=3.5")
981978
end
982979

980+
local envs = _get_envs_for_default_flags(package, configs, opt)
983981
local runtime_envs = _get_envs_for_runtime_flags(package, configs, opt)
984982
if runtime_envs then
985983
envs = envs or {}

0 commit comments

Comments
 (0)