summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2013-04-30 17:45:22 +0200
committerRobin Gareus <robin@gareus.org>2013-04-30 17:45:22 +0200
commit0b8712268e4935e69fa5604407ee0f7753027fdd (patch)
treea87b1cf50961ae849e7b08713d6469560141d9f3 /tools
parentd54a35a6718e4791ef57d0ad86dc2f41a1ec46a2 (diff)
fix version detection in OSX build script
Diffstat (limited to 'tools')
-rwxr-xr-xtools/osx_packaging/osx_build10
1 files changed, 7 insertions, 3 deletions
diff --git a/tools/osx_packaging/osx_build b/tools/osx_packaging/osx_build
index d750674d36..af582ff3bf 100755
--- a/tools/osx_packaging/osx_build
+++ b/tools/osx_packaging/osx_build
@@ -62,9 +62,13 @@ while [ $# -gt 0 ] ; do
esac
done
-#release_version=`grep -m 1 '[^A-Za-z_]OSX_VERSION = ' ../../wscript | cut -d' ' -f 3 | sed "s/'//g"`
-release_version=3.0
-revision=`grep -m 1 'revision =' ../../libs/ardour/revision.cc | cut -d' ' -f 8 | sed 's/[^0-9]//g'`
+if test -z "$PRODUCT_PKG_DIR" -o -z "$APPNAME"; then
+ echo "application or product-name was not specified"
+ exit 1
+fi
+
+release_version=`grep -m 1 '[^A-Za-z_]OSX_VERSION = ' ../../wscript | cut -d"'" -f2`
+revision=`grep -m 1 'revision =' ../../libs/ardour/revision.cc | cut -d'"' -f 2 | sed 's/^.*-//g'`
echo "Version is $release_version / $revision"
info_string="$release_version/$revision built on `hostname` by `whoami` on `date`"
echo "Info string is $info_string"