diff options
Diffstat (limited to 'xmake/rules/xcode/framework/xmake.lua')
| -rw-r--r-- | xmake/rules/xcode/framework/xmake.lua | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/xmake/rules/xcode/framework/xmake.lua b/xmake/rules/xcode/framework/xmake.lua index de7d7c93c..520ccf1b8 100644 --- a/xmake/rules/xcode/framework/xmake.lua +++ b/xmake/rules/xcode/framework/xmake.lua @@ -105,6 +105,13 @@ rule("xcode.framework") end os.vcp(target:targetfile(), contentsdir) + -- change rpath + -- @see https://github.com/xmake-io/xmake/issues/2679#issuecomment-1221839215 + local filename = path.filename(target:targetfile()) + local targetfile = path.join(contentsdir, filename) + local rpath = path.relative(contentsdir, path.directory(bundledir)) + os.vrunv("install_name_tool", {"-id", path.join("@rpath", rpath, filename), targetfile}) + -- move header files os.tryrm(headersdir) os.mv(path.join(contentsdir, "Headers.tmp", target:basename()), headersdir) |
