mirror of
https://github.com/pyenv/pyenv.git
synced 2024-11-21 20:47:00 -05:00
Add PyPy nightly builds
This commit is contained in:
parent
60e1abe7fa
commit
b986f8f93f
3 changed files with 104 additions and 20 deletions
|
@ -144,6 +144,10 @@ install_package() {
|
|||
install_package_using "tarball" 1 "$@"
|
||||
}
|
||||
|
||||
install_nightly_package() {
|
||||
install_package_using "nightly_tarball" 2 "$@"
|
||||
}
|
||||
|
||||
install_git() {
|
||||
install_package_using "git" 2 "$@"
|
||||
}
|
||||
|
@ -358,6 +362,19 @@ fetch_tarball() {
|
|||
} >&4 2>&1
|
||||
}
|
||||
|
||||
fetch_nightly_tarball() {
|
||||
local package_name="$1"
|
||||
local package_url="$2"
|
||||
local package_pattern="$3"
|
||||
fetch_tarball "$1" "$2"
|
||||
if [ ! -e "${package_name}" ]; then
|
||||
local nightly_package_name="$(echo ${package_pattern})"
|
||||
if [ -e "${nightly_package_name}" ]; then
|
||||
ln -fs "${nightly_package_name}" "${package_name}"
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
reuse_existing_tarball() {
|
||||
local package_filename="$1"
|
||||
local checksum="$2"
|
||||
|
@ -834,31 +851,28 @@ pypy_architecture() {
|
|||
esac
|
||||
;;
|
||||
"CYGWIN"* | "MINGW"* ) echo "win32" ;;
|
||||
"FreeBSD" )
|
||||
case "$(uname -m)" in
|
||||
"x86_64" ) echo "freebsd64" ;;
|
||||
* ) return 1 ;;
|
||||
esac
|
||||
;;
|
||||
* ) return 1 ;;
|
||||
esac
|
||||
}
|
||||
|
||||
build_package_pypy() {
|
||||
build_package_copy
|
||||
{ if [ ! -x "${PREFIX_PATH}/bin/python" ]; then
|
||||
local pypy
|
||||
if [ -x "${PREFIX_PATH}/bin/pypy" ]; then
|
||||
pypy="${PREFIX_PATH}/bin/pypy"
|
||||
elif [ -x "${PREFIX_PATH}/bin/pypy3" ]; then
|
||||
pypy="${PREFIX_PATH}/bin/pypy3"
|
||||
fi
|
||||
if [ -e "${pypy}" ]; then
|
||||
if [ -L "${pypy}" ]; then
|
||||
( cd "${PREFIX_PATH}/bin" && ln -fs "$(resolve_link "${pypy}")" "python" )
|
||||
else
|
||||
( cd "${PREFIX_PATH}/bin" && ln -fs "${pypy}" "python" )
|
||||
fi
|
||||
else
|
||||
echo "not a pypy binary distribution" 1>&3
|
||||
return 1
|
||||
fi
|
||||
fi
|
||||
} >&4 2>&1
|
||||
mkdir -p "${PREFIX_PATH}/bin" "${PREFIX_PATH}/lib"
|
||||
local pypy libpypy
|
||||
shopt -s nullglob
|
||||
for pypy in "bin/pypy"*; do
|
||||
( cd "${PREFIX_PATH}/bin" && ln -fs "$(basename "${pypy}")" "$(basename "${pypy}" | sed -e 's/pypy/python/')" )
|
||||
done
|
||||
for libpypy in "bin/libpypy-c."*; do
|
||||
( cd "${PREFIX_PATH}/lib" && ln -fs "../bin/$(basename "${libpypy}")" "$(basename "${libpypy}")" )
|
||||
done
|
||||
shopt -u nullglob
|
||||
}
|
||||
|
||||
build_package_pypy_builder() {
|
||||
|
@ -875,7 +889,7 @@ build_package_pypy_builder() {
|
|||
mv -f "pypy-c" "bin/pypy"
|
||||
fi
|
||||
for libpypy in "libpypy-c."*; do
|
||||
mv -f "${libpypy}" "lib/"
|
||||
mv -f "${libpypy}" "bin/"
|
||||
done
|
||||
} >&4 2>&1
|
||||
build_package_pypy
|
||||
|
|
35
plugins/python-build/share/python-build/pypy-c-jit-nightly
Normal file
35
plugins/python-build/share/python-build/pypy-c-jit-nightly
Normal file
|
@ -0,0 +1,35 @@
|
|||
case "$(pypy_architecture 2>/dev/null || true)" in
|
||||
"linux" )
|
||||
install_nightly_package "pypy-c-jit-latest-linux" "http://buildbot.pypy.org/nightly/trunk/pypy-c-jit-latest-linux.tar.bz2" "pypy-c-jit-*-linux" "pypy" verify_py27 ensurepip
|
||||
;;
|
||||
"linux-armel" )
|
||||
install_nightly_package "pypy-c-jit-latest-linux-armel" "http://buildbot.pypy.org/nightly/trunk/pypy-c-jit-latest-linux-armel.tar.bz2" "pypy-c-jit-*-linux-armel" "pypy" verify_py27 ensurepip
|
||||
;;
|
||||
"linux-armhf" )
|
||||
if [[ "$(cat /etc/issue 2>/dev/null || true)" == "Raspbian"* ]]; then
|
||||
install_nightly_package "pypy-c-jit-latest-linux-armhf-raspbian" "http://buildbot.pypy.org/nightly/trunk/pypy-c-jit-latest-linux-armhf-raspbian.tar.bz2" "pypy-c-jit-*-linux-armhf-raspbian" "pypy" verify_py27 ensurepip
|
||||
else
|
||||
install_nightly_package "pypy-c-jit-latest-linux-armhf-raring" "http://buildbot.pypy.org/nightly/trunk/pypy-c-jit-latest-linux-armhf-raring.tar.bz2" "pypy-c-jit-*-linux-armhf-raring" "pypy" verify_py27 ensurepip
|
||||
fi
|
||||
;;
|
||||
"linux64" )
|
||||
install_nightly_package "pypy-c-jit-latest-linux64" "http://buildbot.pypy.org/nightly/trunk/pypy-c-jit-latest-linux64.tar.bz2" "pypy-c-jit-*-linux64" "pypy" verify_py27 ensurepip
|
||||
;;
|
||||
"osx64" )
|
||||
install_nightly_package "pypy-c-jit-latest-osx64" "http://buildbot.pypy.org/nightly/trunk/pypy-c-jit-latest-osx64.tar.bz2" "pypy-c-jit-*-osx64" "pypy" verify_py27 ensurepip
|
||||
;;
|
||||
"freebsd64" )
|
||||
install_nightly_package "pypy-c-jit-latest-freebsd64" "http://buildbot.pypy.org/nightly/trunk/pypy-c-jit-latest-freebsd64.tar.bz2" "pypy-c-jit-*-freebsd64" "pypy" verify_py27 ensurepip
|
||||
;;
|
||||
#"win32" )
|
||||
# install_zip "pypy-c-jit-latest-win32" "http://buildbot.pypy.org/nightly/trunk/pypy-c-jit-latest-win32.zip" "pypy" verify_py27 ensurepip
|
||||
# ;;
|
||||
* )
|
||||
{ echo
|
||||
colorize 1 "ERROR"
|
||||
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
|
||||
echo
|
||||
} >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
35
plugins/python-build/share/python-build/pypy-c-nojit-nightly
Normal file
35
plugins/python-build/share/python-build/pypy-c-nojit-nightly
Normal file
|
@ -0,0 +1,35 @@
|
|||
case "$(pypy_architecture 2>/dev/null || true)" in
|
||||
"linux" )
|
||||
install_nightly_package "pypy-c-nojit-latest-linux" "http://buildbot.pypy.org/nightly/trunk/pypy-c-nojit-latest-linux.tar.bz2" "pypy-c-nojit-*-linux" "pypy" verify_py27 ensurepip
|
||||
;;
|
||||
"linux-armel" )
|
||||
install_nightly_package "pypy-c-nojit-latest-linux-armel" "http://buildbot.pypy.org/nightly/trunk/pypy-c-nojit-latest-linux-armel.tar.bz2" "pypy-c-nojit-*-linux-armel" "pypy" verify_py27 ensurepip
|
||||
;;
|
||||
"linux-armhf" )
|
||||
if [[ "$(cat /etc/issue 2>/dev/null || true)" == "Raspbian"* ]]; then
|
||||
install_nightly_package "pypy-c-nojit-latest-linux-armhf-raspbian" "http://buildbot.pypy.org/nightly/trunk/pypy-c-nojit-latest-linux-armhf-raspbian.tar.bz2" "pypy-c-nojit-*-linux-armhf-raspbian" "pypy" verify_py27 ensurepip
|
||||
else
|
||||
install_nightly_package "pypy-c-nojit-latest-linux-armhf-raring" "http://buildbot.pypy.org/nightly/trunk/pypy-c-nojit-latest-linux-armhf-raring.tar.bz2" "pypy-c-nojit-*-linux-armhf-raring" "pypy" verify_py27 ensurepip
|
||||
fi
|
||||
;;
|
||||
"linux64" )
|
||||
install_nightly_package "pypy-c-nojit-latest-linux64" "http://buildbot.pypy.org/nightly/trunk/pypy-c-nojit-latest-linux64.tar.bz2" "pypy-c-nojit-*-linux64" "pypy" verify_py27 ensurepip
|
||||
;;
|
||||
"osx64" )
|
||||
install_nightly_package "pypy-c-nojit-latest-osx64" "http://buildbot.pypy.org/nightly/trunk/pypy-c-nojit-latest-osx64.tar.bz2" "pypy-c-nojit-*-osx64" "pypy" verify_py27 ensurepip
|
||||
;;
|
||||
"freebsd64" )
|
||||
install_nightly_package "pypy-c-nojit-latest-freebsd64" "http://buildbot.pypy.org/nightly/trunk/pypy-c-nojit-latest-freebsd64.tar.bz2" "pypy-c-nojit-*-freebsd64" "pypy" verify_py27 ensurepip
|
||||
;;
|
||||
#"win32" )
|
||||
# install_zip "pypy-c-nojit-latest-win32" "http://buildbot.pypy.org/nightly/trunk/pypy-c-nojit-latest-win32.zip" "pypy" verify_py27 ensurepip
|
||||
# ;;
|
||||
* )
|
||||
{ echo
|
||||
colorize 1 "ERROR"
|
||||
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
|
||||
echo
|
||||
} >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
Loading…
Reference in a new issue