summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2013-06-11 11:37:52 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2013-06-11 11:37:52 -0400
commit2e1e5da78e1a18cc2b26bf57bf69a260eaf1e163 (patch)
treeb4002d665ef957f286ae60bd96137e05e5d85cab
parentef6366a7cd56157c6468a6c0d87a3e37f6d7c7af (diff)
more changes to consolidate version definition into the top level wscript file
-rw-r--r--gtk2_ardour/wscript10
-rw-r--r--tools/define_versions.sh6
-rw-r--r--wscript8
3 files changed, 11 insertions, 13 deletions
diff --git a/gtk2_ardour/wscript b/gtk2_ardour/wscript
index bba65c8c0a..5a8ecc771c 100644
--- a/gtk2_ardour/wscript
+++ b/gtk2_ardour/wscript
@@ -8,12 +8,6 @@ import re
import time
from waflib.Task import Task
-# Version of this package (even if built as a child)
-MAJOR = '3'
-MINOR = '2'
-
-# Variables for 'waf dist'
-VERSION = "%s.%s" % (MAJOR, MINOR)
I18N_PACKAGE = 'gtk2_ardour3'
# Mandatory variables
@@ -266,7 +260,7 @@ def configure(conf):
autowaf.build_version_files(
path_prefix + 'version.h',
path_prefix + 'version.cc',
- 'gtk2_ardour', MAJOR, MINOR, 0)
+ 'gtk2_ardour', conf.env['MAJOR'], conf.env['MINOR'], 0)
autowaf.configure(conf)
if re.search ("linux", sys.platform) != None:
@@ -364,6 +358,8 @@ def build_color_scheme(path, prefix):
def build(bld):
+ VERSION = "%s.%s" % (bld.env['MAJOR'], bld.env['MINOR'])
+
if bld.is_defined('WINDOWS_VST_SUPPORT'):
# If we require VST support we build a stub main() and the FST library
# here using winegcc, and link it to the GTK front-end library
diff --git a/tools/define_versions.sh b/tools/define_versions.sh
index 6f5c17773c..860414e0a6 100644
--- a/tools/define_versions.sh
+++ b/tools/define_versions.sh
@@ -2,10 +2,8 @@
# this is sourced by build and package, and executed from within build/{osx,linux}_packaging
#
-major_version=`grep -m 1 '^MAJOR = ' ../../wscript | awk '{print $3}' | sed "s/'//g"`
-minor_version=`grep -m 1 '^MINOR = ' ../../wscript | awk '{print $3}' | sed "s/'//g"`
-release_version=${major_version}.${minor_version}
-r=`cut -d'"' -f2 < ../../libs/ardour/revision.cc | sed -e 1d -e "s/[0-9][0-9]*\.[0-9][0-9]*-//"`
+release_version=`grep -m 1 '^VERSION = ' ../../wscript | awk '{print $3}' | sed "s/'//g"`
+r=`cut -d'"' -f2 < ../../libs/ardour/revision.cc | sed -e 1d -e "s/$release_version-//"`
if echo $r | grep -q -e - ; then
revcount=`echo $r | cut -d- -f1`
fi
diff --git a/wscript b/wscript
index dc0279be8c..e5e12754e1 100644
--- a/wscript
+++ b/wscript
@@ -7,9 +7,11 @@ import string
import subprocess
import sys
-VERSION = '3.1'
+MAJOR = '3'
+MINOR = '1'
+VERSION = MAJOR + '.' + MINOR
-APPNAME = 'Ardour3'
+APPNAME = 'Ardour' + MAJOR
# Mandatory variables
top = '.'
@@ -461,6 +463,8 @@ def configure(conf):
conf.load('compiler_c')
conf.load('compiler_cxx')
conf.env['VERSION'] = VERSION
+ conf.env['MAJOR'] = MAJOR
+ conf.env['MINOR'] = MINOR
conf.line_just = 52
autowaf.set_recursive()
autowaf.configure(conf)