aboutsummaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
Diffstat (limited to 'build')
-rw-r--r--build/chirp.app/Contents/Info.plist26
-rwxr-xr-xbuild/chirp.app/Contents/MacOS/chirp19
-rw-r--r--build/chirp.app/Contents/PkgInfo1
-rw-r--r--build/chirp.app/Contents/Resources/.placeholder0
-rw-r--r--build/macos/make_pango.sh51
-rwxr-xr-xbuild/make_source_release.sh23
-rw-r--r--build/version1
7 files changed, 121 insertions, 0 deletions
diff --git a/build/chirp.app/Contents/Info.plist b/build/chirp.app/Contents/Info.plist
new file mode 100644
index 0000000..673eeeb
--- /dev/null
+++ b/build/chirp.app/Contents/Info.plist
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>CFBundleDevelopmentRegion</key>
+ <string>English</string>
+ <key>CFBundleExecutable</key>
+ <string>chirp</string>
+ <key>CFBundleIconFile</key>
+ <string>Chirp</string>
+ <key>CFBundleIdentifier</key>
+ <string>com.danplanet.chirp</string>
+ <key>CFBundleInfoDictionaryVersion</key>
+ <string>6.0</string>
+ <key>CFBundleName</key>
+ <string>chirp</string>
+ <key>CFBundleShortVersionString</key>
+ <string>0.1</string>
+ <key>CFBundleVersion</key>
+ <string>0.1</string>
+ <key>LSHasLocalizedDisplayName</key>
+ <false/>
+ <key>LSMinimumSystemVersion</key>
+ <string>10.5</string>
+</dict>
+</plist>
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"
diff --git a/build/chirp.app/Contents/PkgInfo b/build/chirp.app/Contents/PkgInfo
new file mode 100644
index 0000000..bd04210
--- /dev/null
+++ b/build/chirp.app/Contents/PkgInfo
@@ -0,0 +1 @@
+APPL???? \ No newline at end of file
diff --git a/build/chirp.app/Contents/Resources/.placeholder b/build/chirp.app/Contents/Resources/.placeholder
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/build/chirp.app/Contents/Resources/.placeholder
diff --git a/build/macos/make_pango.sh b/build/macos/make_pango.sh
new file mode 100644
index 0000000..57d3429
--- /dev/null
+++ b/build/macos/make_pango.sh
@@ -0,0 +1,51 @@
+#!/usr/bin/env bash
+
+make_pango_modules() {
+ local src=$1
+ local dst=$2
+ local sf=${src}/etc/pango/pango.modules
+ local df=${dst}/etc/pango/pango.modules
+
+ cat $sf | sed 's/\/opt\/.*\/lib/..\/Resources/' > $df
+}
+
+make_pango_rc() {
+ local src=$1
+ local dst=$2
+ local sf=${src}/etc/pango/pangorc
+ local df=${dst}/etc/pango/pangorc
+
+ cat $sf | sed 's/\/opt\/.*\/etc/.\/etc/' > $df
+}
+
+make_pangox_aliases() {
+ local src=$1
+ local dst=$2
+
+ cp ${src}/etc/pango/pangox.aliases ${dst}/etc/pango
+}
+
+usage() {
+ echo 'Usage: make_pango.sh [PATH_TO_MACPORTS] [PATH_TO_APP]'
+ echo 'Example:'
+ echo ' make_pango.sh /opt/local dist/d-rats.app'
+}
+
+if [ -z "$1" ]; then
+ usage
+ exit 1
+fi
+
+if [ -z "$2" ]; then
+ usage
+ exit 1
+fi
+
+base=$1
+app="$2/Contents/Resources"
+
+mkdir -p ${app}/etc/pango
+
+make_pango_modules $base $app
+make_pango_rc $base $app
+make_pangox_aliases $base $app
diff --git a/build/make_source_release.sh b/build/make_source_release.sh
new file mode 100755
index 0000000..2a5af86
--- /dev/null
+++ b/build/make_source_release.sh
@@ -0,0 +1,23 @@
+#!/usr/bin/env bash
+
+VERSION=$(cat build/version)
+INCLUDE="COPYING"
+TMP=$(mktemp -d)
+EXCLUDE=""
+
+sed -i 's/^CHIRP_VERSION.*$/CHIRP_VERSION=\"'$VERSION'\"/' chirp/__init__.py
+
+RELDIR=chirp-${VERSION}
+
+DST="${TMP}/${RELDIR}"
+
+mkdir -p $DST
+
+cp -rav --parents chirp/*.py chirp/drivers/*.py csvdump/*.py chirp/ui/* $DST
+cp -av *.py ${DST}
+
+cp -rav $INCLUDE ${DST}
+
+(cd $TMP && tar czf - $RELDIR) > ${RELDIR}.tar.gz
+
+rm -Rf ${TMP}/${RELDIR}
diff --git a/build/version b/build/version
new file mode 100644
index 0000000..8508cef
--- /dev/null
+++ b/build/version
@@ -0,0 +1 @@
+0.3.0dev