aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xtools/mac-libs.rb13
1 files changed, 9 insertions, 4 deletions
diff --git a/tools/mac-libs.rb b/tools/mac-libs.rb
index 0c1920f..a66b409 100755
--- a/tools/mac-libs.rb
+++ b/tools/mac-libs.rb
@@ -18,7 +18,8 @@ def executable
end
def get_rpaths(lib)
- out = `otool -l #{lib}`.split("\n")
+ out, _ = Open3.capture2("otool", "-l", lib)
+ out = out.split("\n")
rpaths = []
out.each_with_index do |line, i|
@@ -31,8 +32,8 @@ def get_rpaths(lib)
end
def get_load_libs(lib)
- `otool -L #{lib}`
- .split("\n")
+ out, _ = Open3.capture2("otool", "-L", lib)
+ out.split("\n")
.drop(1)
.map { |it| it.strip.gsub(/ \(.*/, "") }
end
@@ -93,7 +94,8 @@ def install_name_tool(exec, action, path1, path2 = nil)
end
def strip(lib)
- `strip -SNTx "#{lib}"`
+ out, _ = Open3.capture2("strip", "-SNTx", lib)
+ print out
end
def fixup_libs(prog, orig_path)
@@ -218,6 +220,9 @@ Dir.glob("#{frameworks_dir}/**/Headers").each do |dir|
FileUtils.rm_rf dir
end
+out, _ = Open3.capture2("codesign", "-s", "-", "-f", "--deep", $bundle)
+print out
+
if $build_dmg
dmg_dir = File.join($build_dir, "dmg")
FileUtils.mkdir_p(dmg_dir)