summaryrefslogtreecommitdiff
path: root/xmake/modules/package/tools/cmake.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2024-04-21 22:14:15 +0800
committerruki <[email protected]>2024-04-21 22:14:15 +0800
commit561e7792f3a4965877932f2372138a018de75aea (patch)
tree59ca20c12b1abbd49c150aa1282ef9d6e7444f70 /xmake/modules/package/tools/cmake.lua
parent0ec4f8b72c4c4acdeab62645670198b88efa917f (diff)
fix runtimes
Diffstat (limited to 'xmake/modules/package/tools/cmake.lua')
-rw-r--r--xmake/modules/package/tools/cmake.lua10
1 files changed, 5 insertions, 5 deletions
diff --git a/xmake/modules/package/tools/cmake.lua b/xmake/modules/package/tools/cmake.lua
index 063d13cb8..da049389e 100644
--- a/xmake/modules/package/tools/cmake.lua
+++ b/xmake/modules/package/tools/cmake.lua
@@ -186,7 +186,7 @@ function _get_cxxflags(package, opt)
end
local runtimes = package:runtimes()
if runtimes then
- local fake_target = {is_shared = function(_) return false end,
+ local fake_target = {is_shared = function(_) return false end,
sourcekinds = function(_) return "cxx" end}
table.join2(result, _map_compflags(fake_target, "cxx", "runtime", runtimes))
end
@@ -239,9 +239,9 @@ function _get_ldflags(package, opt)
table.join2(result, _map_linkflags(package, "binary", {"cxx"}, "syslink", package:build_getenv("syslinks")))
table.join2(result, _map_linkflags(package, "binary", {"cxx"}, "linkdir", package:build_getenv("linkdirs")))
end
- local runtimes = package:config("runtimes")
+ local runtimes = package:runtimes()
if runtimes then
- local fake_target = {is_shared = function(_) return false end,
+ local fake_target = {is_shared = function(_) return false end,
sourcekinds = function(_) return "cxx" end}
table.join2(result, _map_linkflags(fake_target, "binary", {"cxx"}, "runtime", runtimes))
end
@@ -271,9 +271,9 @@ function _get_shflags(package, opt)
table.join2(result, _map_linkflags(package, "shared", {"cxx"}, "syslink", package:build_getenv("syslinks")))
table.join2(result, _map_linkflags(package, "shared", {"cxx"}, "linkdir", package:build_getenv("linkdirs")))
end
- local runtimes = package:config("runtimes")
+ local runtimes = package:runtimes()
if runtimes then
- local fake_target = {is_shared = function(_) return true end,
+ local fake_target = {is_shared = function(_) return true end,
sourcekinds = function(_) return "cxx" end}
table.join2(result, _map_linkflags(fake_target, "shared", {"cxx"}, "runtime", runtimes))
end