From fe5c48cbed29b669f17370436d0cf18ca0ccb474 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Tue, 16 Nov 2010 12:05:14 +1100 Subject: waf: added --git-local-changes configure option if you use --git-local-changes then the version number that waf extracts from git will have a '+' on the end if you have local changes, as determined by running 'git diff'. This used to be the default, but unfortunately it is far too slow on some systems. On a NFS build system I was using the first line of configure took about 2 minutes. Autobuild-User: Andrew Tridgell Autobuild-Date: Tue Nov 16 01:51:54 UTC 2010 on sn-devel-104 --- source3/wscript | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'source3/wscript') diff --git a/source3/wscript b/source3/wscript index 1164ff1d70..510bed5749 100644 --- a/source3/wscript +++ b/source3/wscript @@ -14,14 +14,14 @@ import build.charset import samba_utils import samba3 -def load_version(have_git=False): +def load_version(env=None): '''load samba versions either from ./VERSION or git return a version object for detailed breakdown''' import samba_utils, Utils - if not have_git: + if not env: env = samba_utils.LOAD_ENVIRONMENT() - have_git = 'GIT' in env - version = wafsamba.samba_version_file("./VERSION", "..", have_git=have_git) + + version = wafsamba.samba_version_file("./VERSION", "..", env=env) Utils.g_module.VERSION = version.STRING return version @@ -67,7 +67,7 @@ def set_options(opt): def configure(conf): from samba_utils import TO_LIST - version = load_version(have_git=True) + version = load_version(env=conf.env) conf.DEFINE('CONFIG_H_IS_FROM_SAMBA', 1) conf.DEFINE('_SAMBA_BUILD_', version.MAJOR, add_to_cflags=True) -- cgit