Commit 9a9ed692 authored by Mike Perry's avatar Mike Perry
Browse files

We now support python2.6 or python2.7.

Adjust setup accordingly. Also bump other version deps.
parent a26bf21b
......@@ -41,12 +41,9 @@ prepare a virtualenv, or run through the setup manually.
2.1. Scripted virtualenv setup
The easiest and most reliable setup method is to use the setup.sh script
to install a python 2.6 virtual environment. This script will download all
to install a python 2.6/2.7 virtual environment. This script will download all
of the dependencies and install them for you, but it will require that you
have a copy of python2.6 installed and in your path.
There is also a install-debs.sh script for Debian and Ubuntu systems that will
handle python2.6 and some additional package dependency installation for you.
have a copy of python2.6 or python2.7 installed and in your path.
2.2. Manual setup
......
......@@ -10,7 +10,6 @@ OUTPUT=$SCANNER_DIR/bwscan.V3BandwidthsFile
cd $SCANNER_DIR # Needed for import to work properly.
if [ -f bwauthenv/bin/activate ]
then
echo "Using virtualenv..."
. bwauthenv/bin/activate
fi
$SCANNER_DIR/aggregate.py $SCANNER_DIR/data $OUTPUT
......
#!/bin/bash
if [ ! $(dpkg -s python2.6 python2.6-dev 2>/dev/null >/dev/null) ]
then
echo "We need python2.6 to be in the path. Press enter to try to install it."
echo "or control-c and find your own way to install it and re-run this script"
echo
echo -n "Hit enter to install python2.6: "
read
sudo apt-get install python2.6 python2.6-dev
if [ $? -ne 0 ]
then
echo
echo "Your distribution does not natively provide python2.6."
echo "Press enter to try to install from a ppa, or control-c to install on your own"
echo
echo -n "Hit enter to install from ppa:fkrull/deadsnakes: "
read
sudo apt-get install software-properties-common
sudo add-apt-repository ppa:fkrull/deadsnakes
sudo apt-get update
sudo apt-get install python2.6 python2.6-dev
fi
fi
sudo apt-get install libsqlite3-dev python-virtualenv
sudo apt-get install autoconf2.13 automake make libevent-dev
......@@ -19,11 +19,11 @@
#
# (Or, if you didn't install peep, do `$ pip install -r requirements.txt`.)
# sha256: NUKQvRsYu2nhGUay2RP9mxXCpKp94uhWXSmUktt3NyE
pysqlite==2.6.0
# sha256: _pw1IWv1bIWLNMS0yL5-NFZt3vKWcOWltD-cuOz7so0
pysqlite==2.6.3
# sha256: tYgFyp-PUSPmCfJTqRboeh4-rERqCq4Sjt5jBIXI9AY
SQLAlchemy==0.7.2
# sha256: d6o51lydBD66a6Mps1n_hnQk_WxAO3wMsRK2XlB-HWY
SQLAlchemy==0.7.10
# sha256: p-9DfyW1ROT3T7Mjb8Q80l9db-tgN918ZpMQRtdUOek
Elixir==0.7.1
......@@ -51,7 +51,7 @@ fi
if [ -f bwauthenv/bin/activate ]
then
echo "Using virtualenv..."
echo "Using virtualenv in bwauthenv..."
. bwauthenv/bin/activate
fi
......
......@@ -3,18 +3,21 @@
SCANNER_DIR=$(dirname "$0")
SCANNER_DIR=$(readlink -f "$SCANNER_DIR")
# 1. Install python2.6 if needed
if [ -z "$(which python2.6)" ]
PYTHON=$(which python2.6 || which python2.7)
# 1. Install python if needed
if [ -z "$(which $PYTHON)" ]
then
echo "We need python2.6 to be in the path."
echo "If you are on a Debian or Ubuntu system, you can try ./install-debs.sh"
echo "We need python2.6 or 2.7 to be in the path."
echo "If you are on a Debian or Ubuntu system, you can try: "
echo " sudo apt-get install python2.7 python2.7-dev libpython2.7-dev libsqlite3-dev python-virtualenv autoconf2.13 automake make libevent-dev"
exit 1
fi
if [ -z "$(which virtualenv)" ]
then
echo "We need virtualenv to be in the path. If you are on a debian system, try:"
echo " sudo apt-get install libsqlite3-dev python-virtualenv"
echo " sudo apt-get install python-dev libsqlite3-dev python-virtualenv autoconf2.13 automake make libevent-dev"
exit 1
fi
......@@ -39,7 +42,7 @@ fi
# 4. Initialize virtualenv
if [ ! -f bwauthenv/bin/activate ]
then
virtualenv -p python2.6 bwauthenv
virtualenv -p $PYTHON bwauthenv
fi
source bwauthenv/bin/activate
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment