summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorBrian Lamar <brian.lamar@rackspace.com>2011-05-19 16:04:37 -0400
committerBrian Lamar <brian.lamar@rackspace.com>2011-05-19 16:04:37 -0400
commitafa8bb371a3e9f3e770107acabd341334b8d4847 (patch)
treed51b0ba69f68fccc3c2ff0a786922be13d40414d /tools
parent2b70b10d01892b955e4b7b031b4fe554a42a14ec (diff)
parent330b3febe9970a0358cbc145ea88faeb3da121d5 (diff)
downloadnova-afa8bb371a3e9f3e770107acabd341334b8d4847.tar.gz
nova-afa8bb371a3e9f3e770107acabd341334b8d4847.tar.xz
nova-afa8bb371a3e9f3e770107acabd341334b8d4847.zip
Merged trunk and resolved horrible horrible conflicts.
Diffstat (limited to 'tools')
-rw-r--r--tools/install_venv.py10
-rw-r--r--tools/pip-requires2
2 files changed, 9 insertions, 3 deletions
diff --git a/tools/install_venv.py b/tools/install_venv.py
index 30ec85374..8149a3afa 100644
--- a/tools/install_venv.py
+++ b/tools/install_venv.py
@@ -1,3 +1,4 @@
+
# vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2010 United States Government as represented by the
@@ -31,11 +32,15 @@ ROOT = os.path.dirname(os.path.dirname(os.path.realpath(__file__)))
VENV = os.path.join(ROOT, '.nova-venv')
PIP_REQUIRES = os.path.join(ROOT, 'tools', 'pip-requires')
TWISTED_NOVA='http://nova.openstack.org/Twisted-10.0.0Nova.tar.gz'
+PY_VERSION = "python" + str(sys.version_info[0]) + '.' + str(sys.version_info[1])
def die(message, *args):
print >>sys.stderr, message % args
sys.exit(1)
+def check_python_version():
+ if sys.version_info < (2, 6):
+ die("Need Python Version >= 2.6")
def run_command(cmd, redirect_output=True, check_exit_code=True):
"""
@@ -100,12 +105,12 @@ def install_dependencies(venv=VENV):
# Tell the virtual env how to "import nova"
- pthfile = os.path.join(venv, "lib", "python2.6", "site-packages", "nova.pth")
+ pthfile = os.path.join(venv, "lib", PY_VERSION, "site-packages", "nova.pth")
f = open(pthfile, 'w')
f.write("%s\n" % ROOT)
# Patch eventlet (see FAQ # 1485)
patchsrc = os.path.join(ROOT, 'tools', 'eventlet-patch')
- patchfile = os.path.join(venv, "lib", "python2.6", "site-packages", "eventlet",
+ patchfile = os.path.join(venv, "lib", PY_VERSION, "site-packages", "eventlet",
"green", "subprocess.py")
patch_cmd = "patch %s %s" % (patchfile, patchsrc)
os.system(patch_cmd)
@@ -134,6 +139,7 @@ def print_help():
def main(argv):
+ check_python_version()
check_dependencies()
create_virtualenv()
install_dependencies()
diff --git a/tools/pip-requires b/tools/pip-requires
index f7eb1703e..8f8018765 100644
--- a/tools/pip-requires
+++ b/tools/pip-requires
@@ -2,7 +2,7 @@ SQLAlchemy==0.6.3
pep8==0.5.0
pylint==0.19
IPy==0.70
-Cheetah==2.4.2.1
+Cheetah==2.4.4
M2Crypto==0.20.2
amqplib==0.6.1
anyjson==0.2.4