diff options
| author | ruki <[email protected]> | 2022-08-31 00:11:13 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2022-08-31 00:11:13 +0800 |
| commit | 20e5768e36de8c12314c2dacd344cf18807c66f9 (patch) | |
| tree | 88145f036994f9aaaf23dae0d38cdb8acf323948 /xmake/rules/xcode/application | |
| parent | 7f94e5c1d69edcbf1b9b0338e015bfc5e5275883 (diff) | |
improve to install frameworks
Diffstat (limited to 'xmake/rules/xcode/application')
| -rw-r--r-- | xmake/rules/xcode/application/build.lua | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/xmake/rules/xcode/application/build.lua b/xmake/rules/xcode/application/build.lua index b39c3546e..8089be966 100644 --- a/xmake/rules/xcode/application/build.lua +++ b/xmake/rules/xcode/application/build.lua @@ -29,13 +29,13 @@ import("utils.progress") -- -- TODO we should improve os.cp to support for copying directory with symlink -- os.vcp(frameworkdir, frameworksdir, {symlink = true}) -function _copy_frameworks(frameworkdir, frameworksdir) +function copy_frameworks(frameworkdir, frameworksdir) os.mkdir(frameworksdir) local frameworkdir_dst = path.join(frameworksdir, path.filename(frameworkdir)) os.tryrm(frameworkdir_dst) for _, filepath in ipairs(os.filedirs(path.join(frameworkdir, "*"))) do if path.filename(filepath) == "Versions" then - _copy_frameworks(filepath, frameworkdir_dst) + copy_frameworks(filepath, frameworkdir_dst) else local dstpath = path.join(frameworkdir_dst, path.filename(filepath)) os.tryrm(dstpath) @@ -77,7 +77,7 @@ function main (target, opt) if dep:kind() == "shared" then local frameworkdir = dep:data("xcode.bundle.rootdir") if dep:rule("xcode.framework") and frameworkdir then - _copy_frameworks(frameworkdir, frameworksdir, {symlink = true}) + copy_frameworks(frameworkdir, frameworksdir, {symlink = true}) else os.vcp(dep:targetfile(), binarydir) end |
