summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2020-04-04 19:33:57 +0800
committerruki <[email protected]>2020-04-04 19:33:57 +0800
commit06fd899783907bef41d1c3b4d6a7b5ed9a06b54c (patch)
tree788fa960a2619d1476b9805da50d250630c715f8
parent08acbfa0837ce1e9cd45d8d626ffbda996073007 (diff)
disable inherit links
-rw-r--r--xmake/core/project/target.lua2
-rw-r--r--xmake/rules/xcode/framework/xmake.lua2
2 files changed, 3 insertions, 1 deletions
diff --git a/xmake/core/project/target.lua b/xmake/core/project/target.lua
index 4d244ee4f..51eef59b9 100644
--- a/xmake/core/project/target.lua
+++ b/xmake/core/project/target.lua
@@ -326,7 +326,7 @@ end
-- get user private data
function _instance:data(name)
- return self._DATA and self._DATA[name] or nil
+ return self._DATA and self._DATA[name]
end
-- set user private data
diff --git a/xmake/rules/xcode/framework/xmake.lua b/xmake/rules/xcode/framework/xmake.lua
index 78a72a031..f4439acb6 100644
--- a/xmake/rules/xcode/framework/xmake.lua
+++ b/xmake/rules/xcode/framework/xmake.lua
@@ -23,6 +23,7 @@ rule("xcode.framework")
-- we must set kind before target.on_load(), may we will use target in on_load()
before_load(function (target)
+
-- get framework directory
local targetdir = target:targetdir()
@@ -35,6 +36,7 @@ rule("xcode.framework")
target:set("targetdir", path.join(frameworkdir, "Versions", "A"))
-- export frameworks for `add_deps()`
+ target:data_set("inherit.links", false) -- disable to inherit links, @see rule("utils.inherit.links")
target:add("frameworks", target:basename(), {interface = true})
target:add("frameworkdirs", targetdir, {interface = true})