[frogr] Added script to create the Mac OS X bundle
- From: Mario Sanchez Prada <msanchez src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [frogr] Added script to create the Mac OS X bundle
- Date: Tue, 18 Dec 2012 16:17:11 +0000 (UTC)
commit 8086e45a20e868697e4825e57d1628f310abc024
Author: Mario Sanchez Prada <msanchez gnome org>
Date: Mon Dec 17 22:17:22 2012 +0100
Added script to create the Mac OS X bundle
macosx/makebundle.sh | 48 ++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 48 insertions(+), 0 deletions(-)
---
diff --git a/macosx/makebundle.sh b/macosx/makebundle.sh
new file mode 100755
index 0000000..5d134c2
--- /dev/null
+++ b/macosx/makebundle.sh
@@ -0,0 +1,48 @@
+#!/bin/bash
+
+# Copied and modified from GEdit
+
+if [ -d frogr.app ] && [ "$1x" = "-fx" ]; then
+ rm -rf frogr.app
+fi
+
+if [ ! -d frogr.app ]; then
+ echo "Creating new frogr.app bundle..."
+ gtk-mac-bundler frogr.bundle
+else
+ echo "Note frogr.app bundle already exists, only stripping it..."
+fi
+
+function do_strip {
+ tp=$(file -b --mime-type "$1")
+
+ if [ "$tp" != "application/octet-stream" ]; then
+ return
+ fi
+
+ name=$(mktemp -t bundle)
+ st=$(stat -f %p "$1")
+
+ strip -o "$name" -S "$1"
+ mv -f "$name" "$1"
+
+ chmod "$st" "$1"
+ chmod u+w "$1"
+}
+
+echo "Strip debug symbols from bundle binaries"
+
+# Strip debug symbols
+for i in $(find -E frogr.app/Contents/Resources -type f -regex '.*\.(so|dylib)$'); do
+ do_strip "$i"
+done
+
+if [ -d frogr.app/Contents/Resources/bin ]; then
+ for i in $(find frogr.app/Contents/Resources/bin -type f); do
+ if [ -x "$i" ]; then
+ do_strip "$i"
+ fi
+ done
+fi
+
+do_strip frogr.app/Contents/MacOS/frogr-bin
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]