54 lines
2.3 KiB
Groff
54 lines
2.3 KiB
Groff
require_distro() {
|
|
if [[ "$(cat /etc/issue 2>/dev/null || true)" != "$1"* ]]; then
|
|
{ echo
|
|
colorize 1 "WARNING"
|
|
echo ": The binary distribution of PyPy is built for $1."
|
|
echo "installed binary may not run expectedly on other platforms."
|
|
echo
|
|
} >&2
|
|
return 1
|
|
fi
|
|
}
|
|
|
|
case "$(pypy_architecture 2>/dev/null || true)" in
|
|
"linux" )
|
|
require_distro "Ubuntu 10.04" || true
|
|
install_package "pypy-2.2-linux" "https://bitbucket.org/pypy/pypy/downloads/pypy-2.2-linux.tar.bz2#28b38b2417c3cad4c32db120f718bcd9" "pypy" verify_py27
|
|
;;
|
|
"linux-armel" )
|
|
require_distro "Ubuntu 12.04" || true
|
|
install_package "pypy-2.2-linux-armel" "https://bitbucket.org/pypy/pypy/downloads/pypy-2.2-linux-armel.tar.bz2#c50373a6c2517b43c65fd84ac2cd3a6f" "pypy" verify_py27
|
|
;;
|
|
"linux-armhf" )
|
|
if [[ "$(cat /etc/issue 2>/dev/null || true)" == "Raspbian"* ]]; then
|
|
install_package "pypy-2.2-linux-armhf-raspbian" "https://bitbucket.org/pypy/pypy/downloads/pypy-2.2-linux-armhf-raspbian.tar.bz2#e9c9f28cba22d07445e9195c1d2fede6" "pypy" verify_py27
|
|
else
|
|
require_distro "Ubuntu 13.04" || true
|
|
install_package "pypy-2.2-linux-armhf-raring" "https://bitbucket.org/pypy/pypy/downloads/pypy-2.2-linux-armhf-raring.tar.bz2#830fdcfafae461d8e72daa94a1ab4499" "pypy" verify_py27
|
|
fi
|
|
;;
|
|
"linux64" )
|
|
require_distro "Ubuntu 12.04" || true
|
|
install_package "pypy-2.2-linux64" "https://bitbucket.org/pypy/pypy/downloads/pypy-2.2-linux64.tar.bz2#2ce3be921d063eff8286be2e82649638" "pypy" verify_py27
|
|
;;
|
|
"osx64" )
|
|
install_package "pypy-2.2-osx64" "https://bitbucket.org/pypy/pypy/downloads/pypy-2.2-osx64.tar.bz2#690783f07340888a0fa180789de789da" "pypy" verify_py27
|
|
;;
|
|
"win32" )
|
|
# FIXME: never tested on Windows
|
|
install_zip "pypy-2.2-win32" "https://bitbucket.org/pypy/pypy/downloads/pypy-2.2-win32.zip#b44e65f0a7951c0f7eb4338f89120120" "pypy" verify_py27
|
|
;;
|
|
* )
|
|
{ echo
|
|
colorize 1 "ERROR"
|
|
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
|
|
echo "try 'pypy-2.2-src' to build from soruce."
|
|
echo
|
|
} >&2
|
|
exit 1
|
|
;;
|
|
esac
|
|
|
|
install_package "setuptools-3.4.3" "https://pypi.python.org/packages/source/s/setuptools/setuptools-3.4.3.tar.gz#284bf84819c0f6735c853619d1a54955" python
|
|
install_package "pip-1.5.4" "https://pypi.python.org/packages/source/p/pip/pip-1.5.4.tar.gz#834b2904f92d46aaa333267fb1c922bb" python
|