From d7e90f4160aaa81e30206c80047b82833c049482 Mon Sep 17 00:00:00 2001 From: Oz Linden Date: Thu, 7 Feb 2013 11:56:57 -0500 Subject: derive version number from indra/VIEWER_VERSION.txt --- indra/lib/python/indra/util/llmanifest.py | 41 +++++++++---------------------- 1 file changed, 11 insertions(+), 30 deletions(-) (limited to 'indra/lib/python') diff --git a/indra/lib/python/indra/util/llmanifest.py b/indra/lib/python/indra/util/llmanifest.py index 97cc31bba0..eaa94925b1 100644 --- a/indra/lib/python/indra/util/llmanifest.py +++ b/indra/lib/python/indra/util/llmanifest.py @@ -84,28 +84,6 @@ def get_default_platform(dummy): 'darwin':'darwin' }[sys.platform] -def get_default_version(srctree): - # look up llversion.h and parse out the version info - paths = [os.path.join(srctree, x, 'llversionviewer.h') for x in ['llcommon', '../llcommon', '../../indra/llcommon.h']] - for p in paths: - if os.path.exists(p): - contents = open(p, 'r').read() - major = re.search("LL_VERSION_MAJOR\s=\s([0-9]+)", contents).group(1) - minor = re.search("LL_VERSION_MINOR\s=\s([0-9]+)", contents).group(1) - patch = re.search("LL_VERSION_PATCH\s=\s([0-9]+)", contents).group(1) - build = re.search("LL_VERSION_BUILD\s=\s([0-9]+)", contents).group(1) - return major, minor, patch, build - -def get_channel(srctree): - # look up llversionserver.h and parse out the version info - paths = [os.path.join(srctree, x, 'llversionviewer.h') for x in ['llcommon', '../llcommon', '../../indra/llcommon.h']] - for p in paths: - if os.path.exists(p): - contents = open(p, 'r').read() - channel = re.search("LL_CHANNEL\s=\s\"(.+)\";\s*$", contents, flags = re.M).group(1) - return channel - - DEFAULT_SRCTREE = os.path.dirname(sys.argv[0]) DEFAULT_CHANNEL = 'Second Life Release' @@ -140,7 +118,7 @@ ARGUMENTS=[ default=""), dict(name='channel', description="""The channel to use for updates, packaging, settings name, etc.""", - default=get_channel), + default='CHANNEL UNSET'), dict(name='login_channel', description="""The channel to use for login handshake/updates only.""", default=None), @@ -164,10 +142,8 @@ ARGUMENTS=[ contain the name of the final package in a form suitable for use by a .bat file.""", default=None), - dict(name='version', - description="""This specifies the version of Second Life that is - being packaged up.""", - default=get_default_version), + dict(name='versionfile', + description="""The name of a file containing the full version number."""), dict(name='signature', description="""This specifies an identity to sign the viewer with, if any. If no value is supplied, the default signature will be used, if any. Currently @@ -232,9 +208,14 @@ def main(): args[arg['name']] = default # fix up version - if isinstance(args.get('version'), str): - args['version'] = args['version'].split('.') - + if isinstance(args.get('versionfile'), str): + try: # read in the version string + vf = open(args['versionfile'], 'r') + args['version'] = vf.read().strip().split('.') + except: + print "Unable to read versionfile '%s'" % args['versionfile'] + raise + # default and agni are default if args['grid'] in ['default', 'agni']: args['grid'] = '' -- cgit v1.2.3 From 5ea68c69a443fb9364c6e86ec373d3bd57382da7 Mon Sep 17 00:00:00 2001 From: Oz Linden Date: Tue, 12 Feb 2013 10:50:47 -0500 Subject: convert to new channel name scheme and remove login_channel build time parameter --- indra/lib/python/indra/util/llmanifest.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'indra/lib/python') diff --git a/indra/lib/python/indra/util/llmanifest.py b/indra/lib/python/indra/util/llmanifest.py index eaa94925b1..25a1b95b9a 100644 --- a/indra/lib/python/indra/util/llmanifest.py +++ b/indra/lib/python/indra/util/llmanifest.py @@ -85,7 +85,7 @@ def get_default_platform(dummy): }[sys.platform] DEFAULT_SRCTREE = os.path.dirname(sys.argv[0]) -DEFAULT_CHANNEL = 'Second Life Release' +DEFAULT_CHANNEL = 'Second Life Test' ARGUMENTS=[ dict(name='actions', @@ -119,9 +119,6 @@ ARGUMENTS=[ dict(name='channel', description="""The channel to use for updates, packaging, settings name, etc.""", default='CHANNEL UNSET'), - dict(name='login_channel', - description="""The channel to use for login handshake/updates only.""", - default=None), dict(name='installer_name', description=""" The name of the file that the installer should be packaged up into. Only used on Linux at the moment.""", -- cgit v1.2.3 From 237a48721d9df6a8bbf8a3255bb80f348eb2322e Mon Sep 17 00:00:00 2001 From: Oz Linden Date: Fri, 15 Feb 2013 09:29:09 -0500 Subject: clarify windows installer name --- indra/lib/python/indra/util/llmanifest.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/lib/python') diff --git a/indra/lib/python/indra/util/llmanifest.py b/indra/lib/python/indra/util/llmanifest.py index 25a1b95b9a..9cb830a2db 100644 --- a/indra/lib/python/indra/util/llmanifest.py +++ b/indra/lib/python/indra/util/llmanifest.py @@ -85,7 +85,7 @@ def get_default_platform(dummy): }[sys.platform] DEFAULT_SRCTREE = os.path.dirname(sys.argv[0]) -DEFAULT_CHANNEL = 'Second Life Test' +RELEASE_CHANNEL = 'Second Life Release' ARGUMENTS=[ dict(name='actions', @@ -269,7 +269,7 @@ class LLManifest(object): def default_grid(self): return self.args.get('grid', None) == '' def default_channel(self): - return self.args.get('channel', None) == DEFAULT_CHANNEL + return self.args.get('channel', None) == RELEASE_CHANNEL def construct(self): """ Meant to be overriden by LLManifest implementors with code that -- cgit v1.2.3