From 85444c4aff8cc51da35468df62aa70ed87339622 Mon Sep 17 00:00:00 2001 From: David Walter Seikel Date: Wed, 24 Apr 2013 13:04:14 +1000 Subject: Add compatibility with autobuild pre built libraries. Now Imprudence can share them with Kokua. --- linden/scripts/install.py | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) (limited to 'linden/scripts') diff --git a/linden/scripts/install.py b/linden/scripts/install.py index 99e8b73..b39dd5a 100755 --- a/linden/scripts/install.py +++ b/linden/scripts/install.py @@ -565,6 +565,7 @@ windows/i686/vs/2003 -- specify a windows visual studio 2003 package""" tar.extractall(path=install_dir) except AttributeError: _extractall(tar, path=install_dir) + symlinks = [] if _get_platform() == 'linux' or _get_platform() == 'linux64': first = 1 @@ -591,6 +592,43 @@ windows/i686/vs/2003 -- specify a windows visual studio 2003 package""" os.symlink(target, link_name) symlinks += [LINK] print " %s --> %s" % (LINK, target) + + # Reroute autobuilds + auto_name = install_dir + "/include" + if os.path.exists(auto_name): + print "Moving autobuilt include files to legacy locations." + for entry in os.listdir(auto_name): + os.rename(auto_name + "/" + entry, install_dir + "/libraries/include/" + entry) + os.rmdir(auto_name) + + auto_name = install_dir + "/lib" + dest_name = '' + if _get_platform() == 'darwin': + dest_name = 'universal-darwin/' + if _get_platform() == 'linux64': + dest_name = 'x86_64-linux/' + if _get_platform() == 'linux': + dest_name = 'i686-linux/' + if _get_platform() == 'windows': + dest_name = 'i686-win32/' + if os.path.exists(auto_name): + print "Moving autobuilt lib files to legacy locations." + for entry in os.listdir(auto_name): + if os.path.isdir(auto_name + "/" + entry): + path = install_dir + "/libraries/" + dest_name + "lib_" + entry + if entry == 'release': + # Linux is special, coz it's got server code. + if _get_platform() == 'linux' or _get_platform() == 'linux64': + path = install_dir + "/libraries/" + dest_name + "lib_" + entry + "_client" + if not os.path.exists(path): + os.makedirs(path) + for filename in os.listdir(auto_name + "/" + entry): + os.rename(auto_name + "/" + entry + "/" + filename, path + "/" + filename) + os.rmdir(auto_name + "/" + entry) + else: + os.rename(auto_name + "/" + entry, install_dir + "/libraries/" + dest_name + "lib/" + entry) + os.rmdir(auto_name) + if ifile.pkgname in self._installed: self._installed[ifile.pkgname].add_files( ifile.url, -- cgit v1.1