python2.sh 392 B

123456789101112131415161718
  1. #!/bin/bash
  2. RETCODE=$(fw_exists py2)
  3. [ ! "$RETCODE" == 0 ] || { return 0; }
  4. fw_get http://www.python.org/ftp/python/2.7.8/Python-2.7.8.tgz
  5. fw_untar Python-2.7.8.tgz
  6. pre=$(pwd)
  7. cd Python-2.7.8
  8. ./configure --prefix=${pre}/py2 --disable-shared
  9. make -j4
  10. make install
  11. cd ..
  12. if [ ! -f "get-pip.py" ]; then
  13. fw_get https://bootstrap.pypa.io/get-pip.py -O get-pip.py
  14. fi
  15. ./py2/bin/python get-pip.py