aboutsummaryrefslogtreecommitdiff
path: root/build/chirp.app/Contents/MacOS
diff options
context:
space:
mode:
authorMatthew Poletiek <matthew.poletiek@gmail.com>2020-12-08 21:03:16 -0600
committerMatthew Poletiek <matthew.poletiek@gmail.com>2020-12-08 21:03:16 -0600
commite99416456afd4aa8bde42016826f9a345291cbf3 (patch)
treea7a95639cd1cb5dbe2d91a2ca8e8defafac4296d /build/chirp.app/Contents/MacOS
parent194cf4e5e0b6a2811103a9b739a72b9afe2b886c (diff)
downloadchirp-e99416456afd4aa8bde42016826f9a345291cbf3.tar.gz
chirp-e99416456afd4aa8bde42016826f9a345291cbf3.tar.xz
Initial Commit
Diffstat (limited to 'build/chirp.app/Contents/MacOS')
-rwxr-xr-xbuild/chirp.app/Contents/MacOS/chirp19
1 files changed, 19 insertions, 0 deletions
diff --git a/build/chirp.app/Contents/MacOS/chirp b/build/chirp.app/Contents/MacOS/chirp
new file mode 100755
index 0000000..d0ff86e
--- /dev/null
+++ b/build/chirp.app/Contents/MacOS/chirp
@@ -0,0 +1,19 @@
+#!/usr/bin/env bash
+
+LOCATION=$(dirname "${BASH_SOURCE}")
+
+PYTHON=/opt/kk7ds/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python
+
+not_translocated () {
+ security translocate-status-check "${LOCATION}" 2>&1 | grep -q -e NOT -e unknown -e "not found"
+}
+
+if [ ! -x $PYTHON ]; then
+ PYTHON=/opt/kk7ds/bin/python2.7
+elif not_translocated; then
+ ln -s $PYTHON "${LOCATION}/../CHIRP"
+ PYTHON=${LOCATION}/../CHIRP
+ export PYTHONPATH=/opt/kk7ds/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages
+fi
+
+exec "$PYTHON" "${LOCATION}/../Resources/chirp/chirpw"