summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2010-05-28 15:20:03 +1000
committerAndrew Bartlett <abartlet@samba.org>2010-05-28 15:20:03 +1000
commit892a4b24e79a71f5fd81bdb631d93615f2345bd9 (patch)
treec94ced8464b68ef294ea09bbc7b9537693f7892b /source4
parent0ca8e2252b14811b9221acc95a510ab6a84f580f (diff)
downloadsamba-892a4b24e79a71f5fd81bdb631d93615f2345bd9.tar.gz
samba-892a4b24e79a71f5fd81bdb631d93615f2345bd9.tar.bz2
samba-892a4b24e79a71f5fd81bdb631d93615f2345bd9.zip
waf Read VERSION file inside WAF to set package version
This replaces the call to mkversion.sh in both the Samba3 and Samba4 WAF builds. Andrew Bartlett
Diffstat (limited to 'source4')
-rw-r--r--source4/wscript11
1 files changed, 7 insertions, 4 deletions
diff --git a/source4/wscript b/source4/wscript
index 05bee1a6fe..f018094f1c 100644
--- a/source4/wscript
+++ b/source4/wscript
@@ -4,12 +4,15 @@ srcdir = '..'
blddir = 'bin'
APPNAME='samba'
-VERSION='4.0.0-alpha13'
import sys, os
sys.path.insert(0, srcdir+"/buildtools/wafsamba")
import wafsamba, Options, samba_dist, Scripting
+version = wafsamba.samba_version_file("./VERSION")
+
+VERSION=version.STRING
+
samba_dist.DIST_DIRS('.')
# install in /usr/local/samba by default
@@ -38,14 +41,14 @@ def set_options(opt):
def configure(conf):
conf.DEFINE('PACKAGE_NAME', 'samba', quote=True)
- conf.DEFINE('PACKAGE_STRING', 'samba 4', quote=True)
+ conf.DEFINE('PACKAGE_STRING', 'Samba ' + version.STRING, quote=True)
conf.DEFINE('PACKAGE_TARNAME', 'samba', quote=True)
conf.DEFINE('PACKAGE_URL', "http://www.samba.org/", quote=True)
- conf.DEFINE('PACKAGE_VERSION', "4", quote=True)
+ conf.DEFINE('PACKAGE_VERSION', version.STRING, quote=True)
conf.DEFINE('PACKAGE_BUGREPORT', 'http://bugzilla.samba.org/', quote=True)
conf.DEFINE('CONFIG_H_IS_FROM_SAMBA', 1)
- conf.DEFINE('_SAMBA_BUILD_', 4, add_to_cflags=True)
+ conf.DEFINE('_SAMBA_BUILD_', version.MAJOR, add_to_cflags=True)
conf.DEFINE('HAVE_CONFIG_H', 1, add_to_cflags=True)
if Options.options.developer: