From 6d7740c989f421943c429f5f255da3968b0a896a Mon Sep 17 00:00:00 2001 From: Valentin Lab Date: Fri, 28 Jun 2013 17:15:00 +0200 Subject: [PATCH] chg: updated ``python-venv`` to python version 2.7.5 --- precise/python-venv/hooks/install | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/precise/python-venv/hooks/install b/precise/python-venv/hooks/install index 612aba1..e50d0f0 100755 --- a/precise/python-venv/hooks/install +++ b/precise/python-venv/hooks/install @@ -2,17 +2,19 @@ set -eux # -x for verbose logging to juju debug-log +VERSION="2.7.5" + ## -## INSTALL Python 2.7.2 +## INSTALL Python ## apt-get install wget bzip2 build-essential -y --force-yes apt-get install libreadline-dev libbz2-dev libz-dev libssl-dev libsqlite3-dev libgdbm-dev libldap2-dev -y --force-yes cd /tmp -wget http://www.python.org/ftp/python/2.7.2/Python-2.7.2.tar.bz2 -tar xjf Python-2.7.2.tar.bz2 -cd Python-2.7.2 -./configure --prefix=/opt/apps/python-2.7.2 +wget http://www.python.org/ftp/python/$VERSION/Python-$VERSION.tar.bz2 +tar xjf Python-$VERSION.tar.bz2 +cd Python-$VERSION +./configure --prefix=/opt/apps/python-$VERSION make make install @@ -20,11 +22,14 @@ make install ## INSTALL DISTRIBUTE/PIP/VIRTUALENV ## +PYTHON_BASE="/opt/apps/python-$VERSION" +PYTHON_BIN="$PYTHON_BASE/bin" + cd /tmp wget http://python-distribute.org/distribute_setup.py -/opt/apps/python-2.7.2/bin/python ./distribute_setup.py -/opt/apps/python-2.7.2/bin/easy_install pip -/opt/apps/python-2.7.2/bin/pip install virtualenv +"$PYTHON_BIN"/python ./distribute_setup.py +"$PYTHON_BIN"/easy_install pip +"$PYTHON_BIN"/pip install virtualenv ## ## MAKE A DEFAULT VIRTUAL ENV @@ -32,5 +37,5 @@ wget http://python-distribute.org/distribute_setup.py cd /srv mkdir -p /srv/virtualenv -/opt/apps/python-2.7.2/bin/virtualenv /srv/virtualenv/default --no-site-packages +$PYTHON_BIN/virtualenv /srv/virtualenv/default --no-site-packages