mirror of
https://github.com/pyenv/pyenv.git
synced 2025-11-08 11:33:49 -05:00
Compare commits
25 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2bb59169db | ||
|
|
f9e519611a | ||
|
|
ae04877154 | ||
|
|
e82e12739c | ||
|
|
6b9795728e | ||
|
|
23576296ae | ||
|
|
2128b4f27d | ||
|
|
9ba6124833 | ||
|
|
6c63e086e9 | ||
|
|
540c94bdb1 | ||
|
|
18f62f266d | ||
|
|
49cc88094a | ||
|
|
cad18bb332 | ||
|
|
73dc5547fc | ||
|
|
3f0dd1962f | ||
|
|
48b0224aaf | ||
|
|
8cfa967d74 | ||
|
|
a57106c932 | ||
|
|
189e73e5e8 | ||
|
|
8680247381 | ||
|
|
606ff454a1 | ||
|
|
b05d15f673 | ||
|
|
881ba40ff4 | ||
|
|
58bbbf8880 | ||
|
|
c1674cd552 |
42
.github/workflows/modified_scripts_build.yml
vendored
42
.github/workflows/modified_scripts_build.yml
vendored
@@ -32,26 +32,36 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- run: |
|
- run: |
|
||||||
brew install openssl openssl@1.1 readline sqlite3 xz zlib
|
#envvars
|
||||||
- run: |
|
|
||||||
export PYENV_ROOT="$GITHUB_WORKSPACE"
|
export PYENV_ROOT="$GITHUB_WORKSPACE"
|
||||||
echo "PYENV_ROOT=$PYENV_ROOT" >> $GITHUB_ENV
|
echo "PYENV_ROOT=$PYENV_ROOT" >> $GITHUB_ENV
|
||||||
echo "$PYENV_ROOT/shims:$PYENV_ROOT/bin" >> $GITHUB_PATH
|
echo "$PYENV_ROOT/shims:$PYENV_ROOT/bin" >> $GITHUB_PATH
|
||||||
- run: |
|
- run: |
|
||||||
|
#prerequisites
|
||||||
|
brew install openssl openssl@1.1 readline sqlite3 xz zlib
|
||||||
|
if [[ "${{ matrix.python-version }}" =~ pypy.*-(src|dev) ]]; then
|
||||||
|
export PYENV_BOOTSTRAP_VERSION=pypy2.7-7
|
||||||
|
echo "PYENV_BOOTSTRAP_VERSION=$PYENV_BOOTSTRAP_VERSION" >> $GITHUB_ENV
|
||||||
|
pyenv install $PYENV_BOOTSTRAP_VERSION
|
||||||
|
fi
|
||||||
|
- run: |
|
||||||
|
#build
|
||||||
pyenv install -v ${{ matrix.python-version }}
|
pyenv install -v ${{ matrix.python-version }}
|
||||||
pyenv global ${{ matrix.python-version }}
|
pyenv global ${{ matrix.python-version }}
|
||||||
# Micropython doesn't support --version
|
# Micropython doesn't support --version
|
||||||
- run: >
|
- run: |
|
||||||
|
#print version
|
||||||
if [[ "${{ matrix.python-version }}" == "micropython-"* ]]; then
|
if [[ "${{ matrix.python-version }}" == "micropython-"* ]]; then
|
||||||
python -c 'import sys; print(sys.version)'
|
python -c 'import sys; print(sys.version)'
|
||||||
else
|
else
|
||||||
python --version;
|
python --version
|
||||||
python -m pip --version
|
python -m pip --version
|
||||||
fi
|
fi
|
||||||
# Micropython doesn't support sys.executable, os.path, older versions even os
|
# Micropython doesn't support sys.executable, os.path, older versions even os
|
||||||
- env:
|
- env:
|
||||||
EXPECTED_PYTHON: ${{ matrix.python-version }}
|
EXPECTED_PYTHON: ${{ matrix.python-version }}
|
||||||
run: |
|
run: |
|
||||||
|
#check
|
||||||
if [[ "${{ matrix.python-version }}" == "micropython-"* ]]; then
|
if [[ "${{ matrix.python-version }}" == "micropython-"* ]]; then
|
||||||
[[ $(pyenv which python) == "${{ env.PYENV_ROOT }}/versions/${{ matrix.python-version }}/bin/python" ]] || exit 1
|
[[ $(pyenv which python) == "${{ env.PYENV_ROOT }}/versions/${{ matrix.python-version }}/bin/python" ]] || exit 1
|
||||||
python -c 'import sys; assert sys.implementation.name == "micropython"'
|
python -c 'import sys; assert sys.implementation.name == "micropython"'
|
||||||
@@ -82,29 +92,39 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- run: |
|
- run: |
|
||||||
sudo apt-get update -q; sudo apt-get install -yq make build-essential \
|
#envvars
|
||||||
libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev \
|
|
||||||
curl llvm libncurses5-dev libncursesw5-dev \
|
|
||||||
xz-utils tk-dev libffi-dev liblzma-dev
|
|
||||||
- run: |
|
|
||||||
export PYENV_ROOT="$GITHUB_WORKSPACE"
|
export PYENV_ROOT="$GITHUB_WORKSPACE"
|
||||||
echo "PYENV_ROOT=$PYENV_ROOT" >> $GITHUB_ENV
|
echo "PYENV_ROOT=$PYENV_ROOT" >> $GITHUB_ENV
|
||||||
echo "$PYENV_ROOT/shims:$PYENV_ROOT/bin" >> $GITHUB_PATH
|
echo "$PYENV_ROOT/shims:$PYENV_ROOT/bin" >> $GITHUB_PATH
|
||||||
- run: |
|
- run: |
|
||||||
|
#prerequisites
|
||||||
|
sudo apt-get update -q; sudo apt-get install -yq make build-essential \
|
||||||
|
libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev \
|
||||||
|
curl llvm libncurses5-dev libncursesw5-dev \
|
||||||
|
xz-utils tk-dev libffi-dev liblzma-dev
|
||||||
|
if [[ "${{ matrix.python-version }}" =~ pypy.*-(src|dev) ]]; then
|
||||||
|
export PYENV_BOOTSTRAP_VERSION=pypy2.7-7
|
||||||
|
echo "PYENV_BOOTSTRAP_VERSION=$PYENV_BOOTSTRAP_VERSION" >> $GITHUB_ENV
|
||||||
|
pyenv install $PYENV_BOOTSTRAP_VERSION
|
||||||
|
fi
|
||||||
|
- run: |
|
||||||
|
#build
|
||||||
pyenv install -v ${{ matrix.python-version }}
|
pyenv install -v ${{ matrix.python-version }}
|
||||||
pyenv global ${{ matrix.python-version }}
|
pyenv global ${{ matrix.python-version }}
|
||||||
# Micropython doesn't support --version
|
# Micropython doesn't support --version
|
||||||
- run: >
|
- run: |
|
||||||
|
#print version
|
||||||
if [[ "${{ matrix.python-version }}" == "micropython-"* ]]; then
|
if [[ "${{ matrix.python-version }}" == "micropython-"* ]]; then
|
||||||
python -c 'import sys; print(sys.version)'
|
python -c 'import sys; print(sys.version)'
|
||||||
else
|
else
|
||||||
python --version;
|
python --version
|
||||||
python -m pip --version
|
python -m pip --version
|
||||||
fi
|
fi
|
||||||
# Micropython doesn't support sys.executable, os.path, older versions even os
|
# Micropython doesn't support sys.executable, os.path, older versions even os
|
||||||
- env:
|
- env:
|
||||||
EXPECTED_PYTHON: ${{ matrix.python-version }}
|
EXPECTED_PYTHON: ${{ matrix.python-version }}
|
||||||
run: |
|
run: |
|
||||||
|
#check
|
||||||
if [[ "${{ matrix.python-version }}" == "micropython-"* ]]; then
|
if [[ "${{ matrix.python-version }}" == "micropython-"* ]]; then
|
||||||
[[ $(pyenv which python) == "${{ env.PYENV_ROOT }}/versions/${{ matrix.python-version }}/bin/python" ]] || exit 1
|
[[ $(pyenv which python) == "${{ env.PYENV_ROOT }}/versions/${{ matrix.python-version }}/bin/python" ]] || exit 1
|
||||||
python -c 'import sys; assert sys.implementation.name == "micropython"'
|
python -c 'import sys; assert sys.implementation.name == "micropython"'
|
||||||
|
|||||||
19
CHANGELOG.md
19
CHANGELOG.md
@@ -1,4 +1,21 @@
|
|||||||
## Version History
|
# Version History
|
||||||
|
|
||||||
|
## Release 2.3.9
|
||||||
|
|
||||||
|
* Add -latest suffix to miniforge3 by @nwh in https://github.com/pyenv/pyenv/pull/2551
|
||||||
|
* Add PyPy 7.3.10 by @dand-oss in https://github.com/pyenv/pyenv/pull/2553
|
||||||
|
* Add miniforge3 and mambaforge 22.9.0-2 by @smcgivern in https://github.com/pyenv/pyenv/pull/2559
|
||||||
|
* Fix compilation error when building OpenSSL 1.1.1q in MacOS 11+ for 3.9.16 by @lisbethw1130 in https://github.com/pyenv/pyenv/pull/2558
|
||||||
|
* Add `openssl` patches for 3.7.15, 3.7.16, and 3.8.16 by @samdoran in https://github.com/pyenv/pyenv/pull/2564
|
||||||
|
* Add support for Anaconda3-2022.10 by @huypn12 in https://github.com/pyenv/pyenv/pull/2565
|
||||||
|
|
||||||
|
## Release 2.3.8
|
||||||
|
|
||||||
|
* Export detected shell environment in pyenv-init by @ianchen-tw in https://github.com/pyenv/pyenv/pull/2540
|
||||||
|
* Add CPython 3.12.0a3 by @saaketp in https://github.com/pyenv/pyenv/pull/2545
|
||||||
|
* Add CPython 3.11.1 by @anton-petrov in https://github.com/pyenv/pyenv/pull/2549
|
||||||
|
* Add CPython 3.10.9 by @rudisimo in https://github.com/pyenv/pyenv/pull/2544
|
||||||
|
* Add 3.7.16, 3.8.16, 3.9.16 by @chadac in https://github.com/pyenv/pyenv/pull/2550
|
||||||
|
|
||||||
## Release 2.3.7
|
## Release 2.3.7
|
||||||
|
|
||||||
|
|||||||
@@ -12,7 +12,7 @@
|
|||||||
set -e
|
set -e
|
||||||
[ -n "$PYENV_DEBUG" ] && set -x
|
[ -n "$PYENV_DEBUG" ] && set -x
|
||||||
|
|
||||||
version="2.3.7"
|
version="2.3.9"
|
||||||
git_revision=""
|
git_revision=""
|
||||||
|
|
||||||
if cd "${BASH_SOURCE%/*}" 2>/dev/null && git remote -v 2>/dev/null | grep -q pyenv; then
|
if cd "${BASH_SOURCE%/*}" 2>/dev/null && git remote -v 2>/dev/null | grep -q pyenv; then
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
# Summary: Configure the shell environment for pyenv
|
# Summary: Configure the shell environment for pyenv
|
||||||
# Usage: eval "$(pyenv init [-|--path] [--no-push-path] [--no-rehash] [<shell>])"
|
# Usage: eval "$(pyenv init [-|--path] [--no-push-path] [--detect-shell] [--no-rehash] [<shell>])"
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
[ -n "$PYENV_DEBUG" ] && set -x
|
[ -n "$PYENV_DEBUG" ] && set -x
|
||||||
@@ -11,6 +11,7 @@ if [ "$1" = "--complete" ]; then
|
|||||||
echo --path
|
echo --path
|
||||||
echo --no-push-path
|
echo --no-push-path
|
||||||
echo --no-rehash
|
echo --no-rehash
|
||||||
|
echo --detect-shell
|
||||||
echo bash
|
echo bash
|
||||||
echo fish
|
echo fish
|
||||||
echo ksh
|
echo ksh
|
||||||
@@ -33,6 +34,11 @@ do
|
|||||||
shift
|
shift
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ "$args" = "--detect-shell" ]; then
|
||||||
|
mode="detect-shell"
|
||||||
|
shift
|
||||||
|
fi
|
||||||
|
|
||||||
if [ "$args" = "--no-push-path" ]; then
|
if [ "$args" = "--no-push-path" ]; then
|
||||||
no_push_path=1
|
no_push_path=1
|
||||||
shift
|
shift
|
||||||
@@ -76,12 +82,17 @@ function main() {
|
|||||||
print_shell_function
|
print_shell_function
|
||||||
exit 0
|
exit 0
|
||||||
;;
|
;;
|
||||||
|
"detect-shell")
|
||||||
|
detect_profile
|
||||||
|
print_detect_shell
|
||||||
|
exit 0
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
# should never get here
|
# should never get here
|
||||||
exit 2
|
exit 2
|
||||||
}
|
}
|
||||||
|
|
||||||
function help_() {
|
function detect_profile() {
|
||||||
case "$shell" in
|
case "$shell" in
|
||||||
bash )
|
bash )
|
||||||
if [ -e '~/.bash_profile' ]; then
|
if [ -e '~/.bash_profile' ]; then
|
||||||
@@ -105,7 +116,16 @@ function help_() {
|
|||||||
rc='your shell'\''s interactive startup file'
|
rc='your shell'\''s interactive startup file'
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
|
function print_detect_shell() {
|
||||||
|
echo "PYENV_SHELL_DETECT=$shell"
|
||||||
|
echo "PYENV_PROFILE_DETECT=$profile"
|
||||||
|
echo "PYENV_RC_DETECT=$rc"
|
||||||
|
}
|
||||||
|
|
||||||
|
function help_() {
|
||||||
|
detect_profile
|
||||||
{
|
{
|
||||||
case "$shell" in
|
case "$shell" in
|
||||||
fish )
|
fish )
|
||||||
|
|||||||
@@ -219,7 +219,7 @@ if [ -z "${PYENV_BOOTSTRAP_VERSION}" ]; then
|
|||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
if [ -n "$PYENV_BOOTSTRAP_VERSION" ]; then
|
if [ -n "$PYENV_BOOTSTRAP_VERSION" ]; then
|
||||||
for dep in curses genc pycparser; do
|
for dep in pycparser; do
|
||||||
if ! PYENV_VERSION="$PYENV_BOOTSTRAP_VERSION" pyenv-exec python -c "import ${dep}" 1>/dev/null 2>&1; then
|
if ! PYENV_VERSION="$PYENV_BOOTSTRAP_VERSION" pyenv-exec python -c "import ${dep}" 1>/dev/null 2>&1; then
|
||||||
echo "pyenv-install: $VERSION_NAME: PyPy requires \`${dep}' in $PYENV_BOOTSTRAP_VERSION to build from source." >&2
|
echo "pyenv-install: $VERSION_NAME: PyPy requires \`${dep}' in $PYENV_BOOTSTRAP_VERSION to build from source." >&2
|
||||||
exit 1
|
exit 1
|
||||||
|
|||||||
@@ -940,7 +940,13 @@ build_package_micropython() {
|
|||||||
|
|
||||||
pypy_architecture() {
|
pypy_architecture() {
|
||||||
case "$(uname -s)" in
|
case "$(uname -s)" in
|
||||||
"Darwin" ) echo "osx64" ;;
|
"Darwin" )
|
||||||
|
case "$(uname -m)" in
|
||||||
|
"arm64" ) echo "osarm64" ;;
|
||||||
|
"x86_64" ) echo "osx64" ;;
|
||||||
|
* ) return 1 ;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
"Linux" )
|
"Linux" )
|
||||||
case "$(uname -m)" in
|
case "$(uname -m)" in
|
||||||
"armel" ) echo "linux-armel" ;;
|
"armel" ) echo "linux-armel" ;;
|
||||||
|
|||||||
9
plugins/python-build/share/python-build/3.10.9
Normal file
9
plugins/python-build/share/python-build/3.10.9
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
prefer_openssl11
|
||||||
|
export PYTHON_BUILD_CONFIGURE_WITH_OPENSSL=1
|
||||||
|
install_package "openssl-1.1.1o" "https://www.openssl.org/source/openssl-1.1.1o.tar.gz#9384a2b0570dd80358841464677115df785edb941c71211f75076d72fe6b438f" mac_openssl --if has_broken_mac_openssl
|
||||||
|
install_package "readline-8.1" "https://ftpmirror.gnu.org/readline/readline-8.1.tar.gz#f8ceb4ee131e3232226a17f51b164afc46cd0b9e6cef344be87c65962cb82b02" mac_readline --if has_broken_mac_readline
|
||||||
|
if has_tar_xz_support; then
|
||||||
|
install_package "Python-3.10.9" "https://www.python.org/ftp/python/3.10.9/Python-3.10.9.tar.xz#5ae03e308260164baba39921fdb4dbf8e6d03d8235a939d4582b33f0b5e46a83" standard verify_py310 copy_python_gdb ensurepip
|
||||||
|
else
|
||||||
|
install_package "Python-3.10.9" "https://www.python.org/ftp/python/3.10.9/Python-3.10.9.tgz#4ccd7e46c8898f4c7862910a1703aa0e63525913a519abb2f55e26220a914d88" standard verify_py310 copy_python_gdb ensurepip
|
||||||
|
fi
|
||||||
10
plugins/python-build/share/python-build/3.11.1
Normal file
10
plugins/python-build/share/python-build/3.11.1
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
prefer_openssl11
|
||||||
|
export PYTHON_BUILD_CONFIGURE_WITH_OPENSSL=1
|
||||||
|
export PYTHON_BUILD_TCLTK_USE_PKGCONFIG=1
|
||||||
|
install_package "openssl-1.1.1s" "https://www.openssl.org/source/openssl-1.1.1s.tar.gz#c5ac01e760ee6ff0dab61d6b2bbd30146724d063eb322180c6f18a6f74e4b6aa" mac_openssl --if has_broken_mac_openssl
|
||||||
|
install_package "readline-8.2" "https://ftpmirror.gnu.org/readline/readline-8.2.tar.gz#3feb7171f16a84ee82ca18a36d7b9be109a52c04f492a053331d7d1095007c35" mac_readline --if has_broken_mac_readline
|
||||||
|
if has_tar_xz_support; then
|
||||||
|
install_package "Python-3.11.1" "https://www.python.org/ftp/python/3.11.1/Python-3.11.1.tar.xz#85879192f2cffd56cb16c092905949ebf3e5e394b7f764723529637901dfb58f" standard verify_py311 copy_python_gdb ensurepip
|
||||||
|
else
|
||||||
|
install_package "Python-3.11.1" "https://www.python.org/ftp/python/3.11.1/Python-3.11.1.tgz#baed518e26b337d4d8105679caf68c5c32630d702614fc174e98cb95c46bdfa4" standard verify_py311 copy_python_gdb ensurepip
|
||||||
|
fi
|
||||||
@@ -3,7 +3,7 @@ export PYTHON_BUILD_CONFIGURE_WITH_OPENSSL=1
|
|||||||
install_package "openssl-1.1.1s" "https://www.openssl.org/source/openssl-1.1.1s.tar.gz#c5ac01e760ee6ff0dab61d6b2bbd30146724d063eb322180c6f18a6f74e4b6aa" mac_openssl --if has_broken_mac_openssl
|
install_package "openssl-1.1.1s" "https://www.openssl.org/source/openssl-1.1.1s.tar.gz#c5ac01e760ee6ff0dab61d6b2bbd30146724d063eb322180c6f18a6f74e4b6aa" mac_openssl --if has_broken_mac_openssl
|
||||||
install_package "readline-8.2" "https://ftpmirror.gnu.org/readline/readline-8.2.tar.gz#3feb7171f16a84ee82ca18a36d7b9be109a52c04f492a053331d7d1095007c35" mac_readline --if has_broken_mac_readline
|
install_package "readline-8.2" "https://ftpmirror.gnu.org/readline/readline-8.2.tar.gz#3feb7171f16a84ee82ca18a36d7b9be109a52c04f492a053331d7d1095007c35" mac_readline --if has_broken_mac_readline
|
||||||
if has_tar_xz_support; then
|
if has_tar_xz_support; then
|
||||||
install_package "Python-3.12.0a2" "https://www.python.org/ftp/python/3.12.0/Python-3.12.0a2.tar.xz#1eafc1384e532cac6432632a77350ef504a114c4235c1f6f2a85f817f5b1926a" standard verify_py312 copy_python_gdb ensurepip
|
install_package "Python-3.12.0a3" "https://www.python.org/ftp/python/3.12.0/Python-3.12.0a3.tar.xz#1b64b3075e0a9241974e580e09b09c9117a1c4e2be698039201ef1d8a73453d1" standard verify_py312 copy_python_gdb ensurepip
|
||||||
else
|
else
|
||||||
install_package "Python-3.12.0a2" "https://www.python.org/ftp/python/3.12.0/Python-3.12.0a2.tgz#81fa3468cada25f5ac8868230a847999495464f8ab67df1df3e8e8e280df0b2b" standard verify_py312 copy_python_gdb ensurepip
|
install_package "Python-3.12.0a3" "https://www.python.org/ftp/python/3.12.0/Python-3.12.0a3.tgz#fd414e6b6520171f5cefc5cba1067265187a322417f7bdec8d024db7fc8fbe96" standard verify_py312 copy_python_gdb ensurepip
|
||||||
fi
|
fi
|
||||||
9
plugins/python-build/share/python-build/3.7.16
Normal file
9
plugins/python-build/share/python-build/3.7.16
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
prefer_openssl11
|
||||||
|
export PYTHON_BUILD_CONFIGURE_WITH_OPENSSL=1
|
||||||
|
install_package "openssl-1.1.1q" "https://www.openssl.org/source/openssl-1.1.1q.tar.gz#d7939ce614029cdff0b6c20f0e2e5703158a489a72b2507b8bd51bf8c8fd10ca" mac_openssl --if has_broken_mac_openssl
|
||||||
|
install_package "readline-8.1" "https://ftpmirror.gnu.org/readline/readline-8.1.tar.gz#f8ceb4ee131e3232226a17f51b164afc46cd0b9e6cef344be87c65962cb82b02" mac_readline --if has_broken_mac_readline
|
||||||
|
if has_tar_xz_support; then
|
||||||
|
install_package "Python-3.7.16" "https://www.python.org/ftp/python/3.7.16/Python-3.7.16.tar.xz#8338f0c2222d847e904c955369155dc1beeeed806e8d5ef04b00ef4787238bfd" standard verify_py37 copy_python_gdb ensurepip
|
||||||
|
else
|
||||||
|
install_package "Python-3.7.16" "https://www.python.org/ftp/python/3.7.16/Python-3.7.16.tgz#0cf2da07fa464636755215415909e22eb1d058817af4824bc15af8390d05fb38" standard verify_py37 copy_python_gdb ensurepip
|
||||||
|
fi
|
||||||
9
plugins/python-build/share/python-build/3.8.16
Normal file
9
plugins/python-build/share/python-build/3.8.16
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
prefer_openssl11
|
||||||
|
export PYTHON_BUILD_CONFIGURE_WITH_OPENSSL=1
|
||||||
|
install_package "openssl-1.1.1q" "https://www.openssl.org/source/openssl-1.1.1q.tar.gz#d7939ce614029cdff0b6c20f0e2e5703158a489a72b2507b8bd51bf8c8fd10ca" mac_openssl --if has_broken_mac_openssl
|
||||||
|
install_package "readline-8.1" "https://ftpmirror.gnu.org/readline/readline-8.1.tar.gz#f8ceb4ee131e3232226a17f51b164afc46cd0b9e6cef344be87c65962cb82b02" mac_readline --if has_broken_mac_readline
|
||||||
|
if has_tar_xz_support; then
|
||||||
|
install_package "Python-3.8.16" "https://www.python.org/ftp/python/3.8.16/Python-3.8.16.tar.xz#d85dbb3774132473d8081dcb158f34a10ccad7a90b96c7e50ea4bb61f5ce4562" standard verify_py38 copy_python_gdb ensurepip
|
||||||
|
else
|
||||||
|
install_package "Python-3.8.16" "https://www.python.org/ftp/python/3.8.16/Python-3.8.16.tgz#71ca9d935637ed2feb59e90a368361dc91eca472a90acb1d344a2e8178ccaf10" standard verify_py38 copy_python_gdb ensurepip
|
||||||
|
fi
|
||||||
9
plugins/python-build/share/python-build/3.9.16
Normal file
9
plugins/python-build/share/python-build/3.9.16
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
prefer_openssl11
|
||||||
|
export PYTHON_BUILD_CONFIGURE_WITH_OPENSSL=1
|
||||||
|
install_package "openssl-1.1.1q" "https://www.openssl.org/source/openssl-1.1.1q.tar.gz#d7939ce614029cdff0b6c20f0e2e5703158a489a72b2507b8bd51bf8c8fd10ca" mac_openssl --if has_broken_mac_openssl
|
||||||
|
install_package "readline-8.1" "https://ftpmirror.gnu.org/readline/readline-8.1.tar.gz#f8ceb4ee131e3232226a17f51b164afc46cd0b9e6cef344be87c65962cb82b02" mac_readline --if has_broken_mac_readline
|
||||||
|
if has_tar_xz_support; then
|
||||||
|
install_package "Python-3.9.16" "https://www.python.org/ftp/python/3.9.16/Python-3.9.16.tar.xz#22dddc099246dd2760665561e8adb7394ea0cc43a72684c6480f9380f7786439" standard verify_py39 copy_python_gdb ensurepip
|
||||||
|
else
|
||||||
|
install_package "Python-3.9.16" "https://www.python.org/ftp/python/3.9.16/Python-3.9.16.tgz#1ad539e9dbd2b42df714b69726e0693bc6b9d2d2c8e91c2e43204026605140c5" standard verify_py39 copy_python_gdb ensurepip
|
||||||
|
fi
|
||||||
28
plugins/python-build/share/python-build/anaconda3-2022.10
Normal file
28
plugins/python-build/share/python-build/anaconda3-2022.10
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
case "$(anaconda_architecture 2>/dev/null || true)" in
|
||||||
|
"Linux-aarch64" )
|
||||||
|
install_script "Anaconda3-2022.10-Linux-aarch64" "https://repo.anaconda.com/archive/Anaconda3-2022.10-Linux-aarch64.sh#dac187c9fa6cae4ad663937f0ef79c8f" "anaconda" verify_py39
|
||||||
|
;;
|
||||||
|
"Linux-ppc64le" )
|
||||||
|
install_script "Anaconda3-2022.10-Linux-ppc64le" "https://repo.anaconda.com/archive/Anaconda3-2022.10-Linux-ppc64le.sh#8dee159ac42f80eca8ce99ddbfd94099" "anaconda" verify_py39
|
||||||
|
;;
|
||||||
|
"Linux-s390x" )
|
||||||
|
install_script "Anaconda3-2022.10-Linux-s390x" "https://repo.anaconda.com/archive/Anaconda3-2022.10-Linux-s390x.sh#ef2a6accc4d0d77756130198cb481358" "anaconda" verify_py39
|
||||||
|
;;
|
||||||
|
"Linux-x86_64" )
|
||||||
|
install_script "Anaconda3-2022.10-Linux-x86_64" "https://repo.anaconda.com/archive/Anaconda3-2022.10-Linux-x86_64.sh#80256bd7a55509665c4179fd61516745" "anaconda" verify_py39
|
||||||
|
;;
|
||||||
|
"MacOSX-arm64" )
|
||||||
|
install_script "Anaconda3-2022.10-MacOSX-arm64" "https://repo.anaconda.com/archive/Anaconda3-2022.10-MacOSX-arm64.sh#3a5d726f90e11270990e520905cf8466" "anaconda" verify_py39
|
||||||
|
;;
|
||||||
|
"MacOSX-x86_64" )
|
||||||
|
install_script "Anaconda3-2022.10-MacOSX-x86_64" "https://repo.anaconda.com/archive/Anaconda3-2022.10-MacOSX-x86_64.sh#83fe2cbd4b32eeb63e99c3e15d72be85" "anaconda" verify_py39
|
||||||
|
;;
|
||||||
|
* )
|
||||||
|
{ echo
|
||||||
|
colorize 1 "ERROR"
|
||||||
|
echo ": The binary distribution of Anaconda is not available for $(anaconda_architecture 2>/dev/null || true)."
|
||||||
|
echo
|
||||||
|
} >&2
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
esac
|
||||||
25
plugins/python-build/share/python-build/mambaforge-22.9.0-2
Normal file
25
plugins/python-build/share/python-build/mambaforge-22.9.0-2
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
case "$(anaconda_architecture 2>/dev/null || true)" in
|
||||||
|
"Linux-aarch64" )
|
||||||
|
install_script "Mambaforge-22.9.0-2-Linux-aarch64.sh" "https://github.com/conda-forge/miniforge/releases/download/22.9.0-2/Mambaforge-22.9.0-2-Linux-aarch64.sh#26cf4a5cd3a3b9085f75911b459b969d6ff8ab426ef9a8e7ce3b47cc683ead86" "miniconda" verify_py310
|
||||||
|
;;
|
||||||
|
"Linux-ppc64le" )
|
||||||
|
install_script "Mambaforge-22.9.0-2-Linux-ppc64le.sh" "https://github.com/conda-forge/miniforge/releases/download/22.9.0-2/Mambaforge-22.9.0-2-Linux-ppc64le.sh#e13044cdbce8542896dd8b7128a00b691c119e7ad6e872c7de93ec9954b4775d" "miniconda" verify_py310
|
||||||
|
;;
|
||||||
|
"Linux-x86_64" )
|
||||||
|
install_script "Mambaforge-22.9.0-2-Linux-x86_64.sh" "https://github.com/conda-forge/miniforge/releases/download/22.9.0-2/Mambaforge-22.9.0-2-Linux-x86_64.sh#d2bb6c33f2373131fc71283baae9eb81a279708d007e55d627d85abe30c2d0eb" "miniconda" verify_py310
|
||||||
|
;;
|
||||||
|
"MacOSX-arm64" )
|
||||||
|
install_script "Mambaforge-22.9.0-2-MacOSX-arm64.sh" "https://github.com/conda-forge/miniforge/releases/download/22.9.0-2/Mambaforge-22.9.0-2-MacOSX-arm64.sh#21959f1a17a662b3f260e8b04fe2dfe82f1246746875a72f513d39159d8b816b" "miniconda" verify_py310
|
||||||
|
;;
|
||||||
|
"MacOSX-x86_64" )
|
||||||
|
install_script "Mambaforge-22.9.0-2-MacOSX-x86_64.sh" "https://github.com/conda-forge/miniforge/releases/download/22.9.0-2/Mambaforge-22.9.0-2-MacOSX-x86_64.sh#844fc1ac61967990f0cfb9e516e8b0704ac2e500854588fd9851d2790d817bab" "miniconda" verify_py310
|
||||||
|
;;
|
||||||
|
* )
|
||||||
|
{ echo
|
||||||
|
colorize 1 "ERROR"
|
||||||
|
echo ": The binary distribution of Mambaforge is not available for $(anaconda_architecture 2>/dev/null || true)."
|
||||||
|
echo
|
||||||
|
} >&2
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
esac
|
||||||
25
plugins/python-build/share/python-build/miniforge3-22.9.0-2
Normal file
25
plugins/python-build/share/python-build/miniforge3-22.9.0-2
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
case "$(anaconda_architecture 2>/dev/null || true)" in
|
||||||
|
"Linux-aarch64" )
|
||||||
|
install_script "Miniforge3-22.9.0-2-Linux-aarch64.sh" "https://github.com/conda-forge/miniforge/releases/download/22.9.0-2/Miniforge3-22.9.0-2-Linux-aarch64.sh#3d75758c4d98181946b29d391323209752c5a111530738b5e36eba77e8e026aa" "miniconda" verify_py310
|
||||||
|
;;
|
||||||
|
"Linux-ppc64le" )
|
||||||
|
install_script "Miniforge3-22.9.0-2-Linux-ppc64le.sh" "https://github.com/conda-forge/miniforge/releases/download/22.9.0-2/Miniforge3-22.9.0-2-Linux-ppc64le.sh#e84ffc9f018d5b23601106f299fefd25a75afb6fdd3416037ce4b561781156fc" "miniconda" verify_py310
|
||||||
|
;;
|
||||||
|
"Linux-x86_64" )
|
||||||
|
install_script "Miniforge3-22.9.0-2-Linux-x86_64.sh" "https://github.com/conda-forge/miniforge/releases/download/22.9.0-2/Miniforge3-22.9.0-2-Linux-x86_64.sh#180aefcbcf8a9f24123adb9e64e16c9bb16bc3f129bd79a5912ff44f295cc405" "miniconda" verify_py310
|
||||||
|
;;
|
||||||
|
"MacOSX-arm64" )
|
||||||
|
install_script "Miniforge3-22.9.0-2-MacOSX-arm64.sh" "https://github.com/conda-forge/miniforge/releases/download/22.9.0-2/Miniforge3-22.9.0-2-MacOSX-arm64.sh#6ac610dabf9a64574ec83b158b2eb6023bc3de0de9a0c528d4fa876df2a27d13" "miniconda" verify_py310
|
||||||
|
;;
|
||||||
|
"MacOSX-x86_64" )
|
||||||
|
install_script "Miniforge3-22.9.0-2-MacOSX-x86_64.sh" "https://github.com/conda-forge/miniforge/releases/download/22.9.0-2/Miniforge3-22.9.0-2-MacOSX-x86_64.sh#d7f50abd340f63515b2059ed462548f5d395e2f9d7847a98c5428998504f5bff" "miniconda" verify_py310
|
||||||
|
;;
|
||||||
|
* )
|
||||||
|
{ echo
|
||||||
|
colorize 1 "ERROR"
|
||||||
|
echo ": The binary distribution of Miniforge is not available for $(anaconda_architecture 2>/dev/null || true)."
|
||||||
|
echo
|
||||||
|
} >&2
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
esac
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
diff --git a/test/v3ext.c b/test/v3ext.c
|
||||||
|
index 7a240cd706..6cec6f1a9b 100644
|
||||||
|
--- a/test/v3ext.c
|
||||||
|
+++ b/test/v3ext.c
|
||||||
|
@@ -15,6 +15,7 @@
|
||||||
|
#include <openssl/err.h>
|
||||||
|
#include "internal/nelem.h"
|
||||||
|
|
||||||
|
+#include <string.h>
|
||||||
|
#include "testutil.h"
|
||||||
|
|
||||||
|
static const char *infile;
|
||||||
@@ -0,0 +1,310 @@
|
|||||||
|
From: Christian Hammond <christian@beanbaginc.com>
|
||||||
|
Date: Wed, 15 Dec 2021 23:12:36 -0800
|
||||||
|
Subject: Port ctypes and system libffi patches for arm64/macOS 10.15+ to Python 3.7.12
|
||||||
|
|
||||||
|
This ports the following ctypes and libffi pyenv patches for Python
|
||||||
|
2.7.18 to Python 3.7.12:
|
||||||
|
|
||||||
|
* `0004-Use-system-libffi-for-Mac-OS-10.15-and-up.patch`
|
||||||
|
* `0005-ctypes-use-the-correct-ABI-for-variadic-functions.patch`
|
||||||
|
* `0006-ctypes-probe-libffi-for-ffi_closure_alloc-and-ffi_pr.patch`
|
||||||
|
|
||||||
|
These patches enable use of system libffi (fixing a broken `ctypes`
|
||||||
|
module on arm64 targets) and enable calling variadic functions on arm64.
|
||||||
|
They've been combined from patches port from Homebrew to pyenv by Takumi
|
||||||
|
Sueda, updated to work on the Python 3.7.12 codebase.
|
||||||
|
|
||||||
|
The Homebrew patches are themselves backports of changes in Python 3.9
|
||||||
|
and 3.10. That patch can be found at:
|
||||||
|
|
||||||
|
https://github.com/Homebrew/formula-patches/blob/master/python/3.8.7.patch
|
||||||
|
|
||||||
|
diff --git a/Doc/library/ctypes.rst b/Doc/library/ctypes.rst
|
||||||
|
index 715d595b24..7743144978 100644
|
||||||
|
--- a/Doc/library/ctypes.rst
|
||||||
|
+++ b/Doc/library/ctypes.rst
|
||||||
|
@@ -1551,6 +1551,13 @@ They are instances of a private class:
|
||||||
|
value usable as argument (integer, string, ctypes instance). This allows
|
||||||
|
defining adapters that can adapt custom objects as function parameters.
|
||||||
|
|
||||||
|
+ .. attribute:: variadic
|
||||||
|
+
|
||||||
|
+ Assign a boolean to specify that the function takes a variable number of
|
||||||
|
+ arguments. This does not matter on most platforms, but for Apple arm64
|
||||||
|
+ platforms variadic functions have a different calling convention than
|
||||||
|
+ normal functions.
|
||||||
|
+
|
||||||
|
.. attribute:: errcheck
|
||||||
|
|
||||||
|
Assign a Python function or another callable to this attribute. The
|
||||||
|
diff --git a/Lib/test/test_unicode.py b/Lib/test/test_unicode.py
|
||||||
|
index 4ebd82d3e0..7b73c190b6 100644
|
||||||
|
--- a/Lib/test/test_unicode.py
|
||||||
|
+++ b/Lib/test/test_unicode.py
|
||||||
|
@@ -2458,11 +2458,14 @@ class CAPITest(unittest.TestCase):
|
||||||
|
def test_from_format(self):
|
||||||
|
support.import_module('ctypes')
|
||||||
|
from ctypes import (
|
||||||
|
+ c_char_p,
|
||||||
|
pythonapi, py_object, sizeof,
|
||||||
|
c_int, c_long, c_longlong, c_ssize_t,
|
||||||
|
c_uint, c_ulong, c_ulonglong, c_size_t, c_void_p)
|
||||||
|
name = "PyUnicode_FromFormat"
|
||||||
|
_PyUnicode_FromFormat = getattr(pythonapi, name)
|
||||||
|
+ _PyUnicode_FromFormat.argtypes = (c_char_p,)
|
||||||
|
+ _PyUnicode_FromFormat.variadic = True
|
||||||
|
_PyUnicode_FromFormat.restype = py_object
|
||||||
|
|
||||||
|
def PyUnicode_FromFormat(format, *args):
|
||||||
|
diff --git a/Modules/_ctypes/_ctypes.c b/Modules/_ctypes/_ctypes.c
|
||||||
|
index dd0c61fd8a..79137e1dc7 100644
|
||||||
|
--- a/Modules/_ctypes/_ctypes.c
|
||||||
|
+++ b/Modules/_ctypes/_ctypes.c
|
||||||
|
@@ -3174,6 +3174,34 @@ PyCFuncPtr_get_restype(PyCFuncPtrObject *self, void *Py_UNUSED(ignored))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
+static int
|
||||||
|
+PyCFuncPtr_set_variadic(PyCFuncPtrObject *self, PyObject *ob)
|
||||||
|
+{
|
||||||
|
+ StgDictObject *dict = PyObject_stgdict((PyObject *)self);
|
||||||
|
+ assert(dict);
|
||||||
|
+ int r = PyObject_IsTrue(ob);
|
||||||
|
+ if (r == 1) {
|
||||||
|
+ dict->flags |= FUNCFLAG_VARIADIC;
|
||||||
|
+ return 0;
|
||||||
|
+ } else if (r == 0) {
|
||||||
|
+ dict->flags &= ~FUNCFLAG_VARIADIC;
|
||||||
|
+ return 0;
|
||||||
|
+ } else {
|
||||||
|
+ return -1;
|
||||||
|
+ }
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+static PyObject *
|
||||||
|
+PyCFuncPtr_get_variadic(PyCFuncPtrObject *self)
|
||||||
|
+{
|
||||||
|
+ StgDictObject *dict = PyObject_stgdict((PyObject *)self);
|
||||||
|
+ assert(dict); /* Cannot be NULL for PyCFuncPtrObject instances */
|
||||||
|
+ if (dict->flags & FUNCFLAG_VARIADIC)
|
||||||
|
+ Py_RETURN_TRUE;
|
||||||
|
+ else
|
||||||
|
+ Py_RETURN_FALSE;
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
static int
|
||||||
|
PyCFuncPtr_set_argtypes(PyCFuncPtrObject *self, PyObject *ob, void *Py_UNUSED(ignored))
|
||||||
|
{
|
||||||
|
@@ -3219,6 +3247,8 @@ static PyGetSetDef PyCFuncPtr_getsets[] = {
|
||||||
|
{ "argtypes", (getter)PyCFuncPtr_get_argtypes,
|
||||||
|
(setter)PyCFuncPtr_set_argtypes,
|
||||||
|
"specify the argument types", NULL },
|
||||||
|
+ { "variadic", (getter)PyCFuncPtr_get_variadic, (setter)PyCFuncPtr_set_variadic,
|
||||||
|
+ "specify if function takes variable number of arguments", NULL },
|
||||||
|
{ NULL, NULL }
|
||||||
|
};
|
||||||
|
|
||||||
|
@@ -5632,6 +5662,7 @@ PyInit__ctypes(void)
|
||||||
|
PyModule_AddObject(m, "FUNCFLAG_USE_ERRNO", PyLong_FromLong(FUNCFLAG_USE_ERRNO));
|
||||||
|
PyModule_AddObject(m, "FUNCFLAG_USE_LASTERROR", PyLong_FromLong(FUNCFLAG_USE_LASTERROR));
|
||||||
|
PyModule_AddObject(m, "FUNCFLAG_PYTHONAPI", PyLong_FromLong(FUNCFLAG_PYTHONAPI));
|
||||||
|
+ PyModule_AddObject(m, "FUNCFLAG_VARIADIC", PyLong_FromLong(FUNCFLAG_VARIADIC));
|
||||||
|
PyModule_AddStringConstant(m, "__version__", "1.1.0");
|
||||||
|
|
||||||
|
PyModule_AddObject(m, "_memmove_addr", PyLong_FromVoidPtr(memmove));
|
||||||
|
diff --git a/Modules/_ctypes/callproc.c b/Modules/_ctypes/callproc.c
|
||||||
|
index 9cbf9801ad..e7fe11176b 100644
|
||||||
|
--- a/Modules/_ctypes/callproc.c
|
||||||
|
+++ b/Modules/_ctypes/callproc.c
|
||||||
|
@@ -754,7 +756,8 @@ static int _call_function_pointer(int flags,
|
||||||
|
ffi_type **atypes,
|
||||||
|
ffi_type *restype,
|
||||||
|
void *resmem,
|
||||||
|
- int argcount)
|
||||||
|
+ int argcount,
|
||||||
|
+ int argtypecount)
|
||||||
|
{
|
||||||
|
PyThreadState *_save = NULL; /* For Py_BLOCK_THREADS and Py_UNBLOCK_THREADS */
|
||||||
|
PyObject *error_object = NULL;
|
||||||
|
@@ -780,15 +783,39 @@ static int _call_function_pointer(int flags,
|
||||||
|
if ((flags & FUNCFLAG_CDECL) == 0)
|
||||||
|
cc = FFI_STDCALL;
|
||||||
|
#endif
|
||||||
|
- if (FFI_OK != ffi_prep_cif(&cif,
|
||||||
|
- cc,
|
||||||
|
- argcount,
|
||||||
|
- restype,
|
||||||
|
- atypes)) {
|
||||||
|
- PyErr_SetString(PyExc_RuntimeError,
|
||||||
|
- "ffi_prep_cif failed");
|
||||||
|
- return -1;
|
||||||
|
+
|
||||||
|
+#if HAVE_FFI_PREP_CIF_VAR
|
||||||
|
+ /* Everyone SHOULD set f.variadic=True on variadic function pointers, but
|
||||||
|
+ * lots of existing code will not. If there's at least one arg and more
|
||||||
|
+ * args are passed than are defined in the prototype, then it must be a
|
||||||
|
+ * variadic function. */
|
||||||
|
+ if ((flags & FUNCFLAG_VARIADIC) ||
|
||||||
|
+ (argtypecount != 0 && argcount > argtypecount))
|
||||||
|
+ {
|
||||||
|
+ if (FFI_OK != ffi_prep_cif_var(&cif,
|
||||||
|
+ cc,
|
||||||
|
+ argtypecount,
|
||||||
|
+ argcount,
|
||||||
|
+ restype,
|
||||||
|
+ atypes)) {
|
||||||
|
+ PyErr_SetString(PyExc_RuntimeError,
|
||||||
|
+ "ffi_prep_cif_var failed");
|
||||||
|
+ return -1;
|
||||||
|
+ }
|
||||||
|
+ } else {
|
||||||
|
+#endif
|
||||||
|
+ if (FFI_OK != ffi_prep_cif(&cif,
|
||||||
|
+ cc,
|
||||||
|
+ argcount,
|
||||||
|
+ restype,
|
||||||
|
+ atypes)) {
|
||||||
|
+ PyErr_SetString(PyExc_RuntimeError,
|
||||||
|
+ "ffi_prep_cif failed");
|
||||||
|
+ return -1;
|
||||||
|
+ }
|
||||||
|
+#if HAVE_FFI_PREP_CIF_VAR
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
if (flags & (FUNCFLAG_USE_ERRNO | FUNCFLAG_USE_LASTERROR)) {
|
||||||
|
error_object = _ctypes_get_errobj(&space);
|
||||||
|
@@ -1187,9 +1214,8 @@ PyObject *_ctypes_callproc(PPROC pProc,
|
||||||
|
|
||||||
|
if (-1 == _call_function_pointer(flags, pProc, avalues, atypes,
|
||||||
|
rtype, resbuf,
|
||||||
|
- Py_SAFE_DOWNCAST(argcount,
|
||||||
|
- Py_ssize_t,
|
||||||
|
- int)))
|
||||||
|
+ Py_SAFE_DOWNCAST(argcount, Py_ssize_t, int),
|
||||||
|
+ Py_SAFE_DOWNCAST(argtype_count, Py_ssize_t, int)))
|
||||||
|
goto cleanup;
|
||||||
|
|
||||||
|
#ifdef WORDS_BIGENDIAN
|
||||||
|
diff --git a/Modules/_ctypes/ctypes.h b/Modules/_ctypes/ctypes.h
|
||||||
|
index e58f85233c..e45975f6ad 100644
|
||||||
|
--- a/Modules/_ctypes/ctypes.h
|
||||||
|
+++ b/Modules/_ctypes/ctypes.h
|
||||||
|
@@ -285,6 +285,7 @@ PyObject *_ctypes_callproc(PPROC pProc,
|
||||||
|
#define FUNCFLAG_PYTHONAPI 0x4
|
||||||
|
#define FUNCFLAG_USE_ERRNO 0x8
|
||||||
|
#define FUNCFLAG_USE_LASTERROR 0x10
|
||||||
|
+#define FUNCFLAG_VARIADIC 0x20
|
||||||
|
|
||||||
|
#define TYPEFLAG_ISPOINTER 0x100
|
||||||
|
#define TYPEFLAG_HASPOINTER 0x200
|
||||||
|
diff --git a/setup.py b/setup.py
|
||||||
|
index bf90600eaa..48ff120e9a 100644
|
||||||
|
--- a/setup.py
|
||||||
|
+++ b/setup.py
|
||||||
|
@@ -142,6 +142,13 @@ def macosx_sdk_root():
|
||||||
|
|
||||||
|
return MACOS_SDK_ROOT
|
||||||
|
|
||||||
|
+def is_macosx_at_least(vers):
|
||||||
|
+ if host_platform == 'darwin':
|
||||||
|
+ dep_target = sysconfig.get_config_var('MACOSX_DEPLOYMENT_TARGET')
|
||||||
|
+ if dep_target:
|
||||||
|
+ return tuple(map(int, str(dep_target).split('.'))) >= vers
|
||||||
|
+ return False
|
||||||
|
+
|
||||||
|
def is_macosx_sdk_path(path):
|
||||||
|
"""
|
||||||
|
Returns True if 'path' can be located in an OSX SDK
|
||||||
|
@@ -150,6 +157,13 @@ def is_macosx_sdk_path(path):
|
||||||
|
or path.startswith('/System/')
|
||||||
|
or path.startswith('/Library/') )
|
||||||
|
|
||||||
|
+def grep_headers_for(function, headers):
|
||||||
|
+ for header in headers:
|
||||||
|
+ with open(header, 'r') as f:
|
||||||
|
+ if function in f.read():
|
||||||
|
+ return True
|
||||||
|
+ return False
|
||||||
|
+
|
||||||
|
def find_file(filename, std_dirs, paths):
|
||||||
|
"""Searches for the directory where a given file is located,
|
||||||
|
and returns a possibly-empty list of additional directories, or None
|
||||||
|
@@ -1972,7 +1986,11 @@ class PyBuildExt(build_ext):
|
||||||
|
return True
|
||||||
|
|
||||||
|
def detect_ctypes(self, inc_dirs, lib_dirs):
|
||||||
|
- self.use_system_libffi = False
|
||||||
|
+ if not sysconfig.get_config_var("LIBFFI_INCLUDEDIR") and is_macosx_at_least((10,15)):
|
||||||
|
+ self.use_system_libffi = True
|
||||||
|
+ else:
|
||||||
|
+ self.use_system_libffi = '--with-system-ffi' in sysconfig.get_config_var("CONFIG_ARGS")
|
||||||
|
+
|
||||||
|
include_dirs = []
|
||||||
|
extra_compile_args = []
|
||||||
|
extra_link_args = []
|
||||||
|
@@ -2018,30 +2036,47 @@ class PyBuildExt(build_ext):
|
||||||
|
libraries=['m'])
|
||||||
|
self.extensions.extend([ext, ext_test])
|
||||||
|
|
||||||
|
+ ffi_inc = sysconfig.get_config_var("LIBFFI_INCLUDEDIR")
|
||||||
|
+ ffi_lib = None
|
||||||
|
+
|
||||||
|
if host_platform == 'darwin':
|
||||||
|
- if '--with-system-ffi' not in sysconfig.get_config_var("CONFIG_ARGS"):
|
||||||
|
+ if not self.use_system_libffi:
|
||||||
|
return
|
||||||
|
- # OS X 10.5 comes with libffi.dylib; the include files are
|
||||||
|
- # in /usr/include/ffi
|
||||||
|
- inc_dirs.append('/usr/include/ffi')
|
||||||
|
-
|
||||||
|
- ffi_inc = [sysconfig.get_config_var("LIBFFI_INCLUDEDIR")]
|
||||||
|
- if not ffi_inc or ffi_inc[0] == '':
|
||||||
|
- ffi_inc = find_file('ffi.h', [], inc_dirs)
|
||||||
|
- if ffi_inc is not None:
|
||||||
|
- ffi_h = ffi_inc[0] + '/ffi.h'
|
||||||
|
+ ffi_in_sdk = os.path.join(macosx_sdk_root(), "usr/include/ffi")
|
||||||
|
+ if os.path.exists(ffi_in_sdk):
|
||||||
|
+ ffi_inc = ffi_in_sdk
|
||||||
|
+ ffi_lib = 'ffi'
|
||||||
|
+ else:
|
||||||
|
+ # OS X 10.5 comes with libffi.dylib; the include files are
|
||||||
|
+ # in /usr/include/ffi
|
||||||
|
+ inc_dirs.append('/usr/include/ffi')
|
||||||
|
+
|
||||||
|
+ if not ffi_inc:
|
||||||
|
+ found = find_file('ffi.h', [], inc_dirs)
|
||||||
|
+ if found:
|
||||||
|
+ ffi_inc = found[0]
|
||||||
|
+ if ffi_inc:
|
||||||
|
+ ffi_h = ffi_inc + '/ffi.h'
|
||||||
|
if not os.path.exists(ffi_h):
|
||||||
|
ffi_inc = None
|
||||||
|
print('Header file {} does not exist'.format(ffi_h))
|
||||||
|
- ffi_lib = None
|
||||||
|
- if ffi_inc is not None:
|
||||||
|
- for lib_name in ('ffi', 'ffi_pic'):
|
||||||
|
+
|
||||||
|
+ if ffi_lib is None and ffi_inc:
|
||||||
|
+ for lib_name in ('ffi_convenience', 'ffi_pic', 'ffi'):
|
||||||
|
if (self.compiler.find_library_file(lib_dirs, lib_name)):
|
||||||
|
ffi_lib = lib_name
|
||||||
|
break
|
||||||
|
|
||||||
|
if ffi_inc and ffi_lib:
|
||||||
|
- ext.include_dirs.extend(ffi_inc)
|
||||||
|
+ ffi_headers = glob(os.path.join(ffi_inc, '*.h'))
|
||||||
|
+ if grep_headers_for('ffi_closure_alloc', ffi_headers):
|
||||||
|
+ try:
|
||||||
|
+ sources.remove('_ctypes/malloc_closure.c')
|
||||||
|
+ except ValueError:
|
||||||
|
+ pass
|
||||||
|
+ if grep_headers_for('ffi_prep_cif_var', ffi_headers):
|
||||||
|
+ ext.extra_compile_args.append("-DHAVE_FFI_PREP_CIF_VAR=1")
|
||||||
|
+ ext.include_dirs.append(ffi_inc)
|
||||||
|
ext.libraries.append(ffi_lib)
|
||||||
|
self.use_system_libffi = True
|
||||||
|
|
||||||
|
--
|
||||||
|
2.30.1 (Apple Git-130)
|
||||||
|
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
From f2595c038ed7bfd182d9d05d83786106ebd02ca0 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Lawrence D'Anna <64555057+lawrence-danna-apple@users.noreply.github.com>
|
||||||
|
Date: Tue, 30 Jun 2020 02:15:46 -0700
|
||||||
|
Subject: [PATCH] bpo-41100: fix _decimal for arm64 Mac OS (GH-21228)
|
||||||
|
|
||||||
|
Patch by Lawrence Danna.
|
||||||
|
---
|
||||||
|
.../Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst | 1 +
|
||||||
|
Modules/_decimal/libmpdec/mpdecimal.h | 3 +++
|
||||||
|
2 files changed, 4 insertions(+)
|
||||||
|
create mode 100644 Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst
|
||||||
|
|
||||||
|
diff --git a/Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst b/Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst
|
||||||
|
new file mode 100644
|
||||||
|
index 0000000000..d6176d69f0
|
||||||
|
--- /dev/null
|
||||||
|
+++ b/Misc/NEWS.d/next/Core and Builtins/2020-06-30-04-44-29.bpo-41100.PJwA6F.rst
|
||||||
|
@@ -0,0 +1 @@
|
||||||
|
+add arm64 to the allowable Mac OS arches in mpdecimal.h
|
||||||
|
\ No newline at end of file
|
||||||
|
diff --git a/Modules/_decimal/libmpdec/mpdecimal.h b/Modules/_decimal/libmpdec/mpdecimal.h
|
||||||
|
index a67dd9bc12..3e9c8185c3 100644
|
||||||
|
--- a/Modules/_decimal/libmpdec/mpdecimal.h
|
||||||
|
+++ b/Modules/_decimal/libmpdec/mpdecimal.h
|
||||||
|
@@ -135,6 +135,9 @@ const char *mpd_version(void);
|
||||||
|
#elif defined(__x86_64__)
|
||||||
|
#define CONFIG_64
|
||||||
|
#define ASM
|
||||||
|
+ #elif defined(__arm64__)
|
||||||
|
+ #define CONFIG_64
|
||||||
|
+ #define ANSI
|
||||||
|
#else
|
||||||
|
#error "unknown architecture for universal build."
|
||||||
|
#endif
|
||||||
|
--
|
||||||
|
2.37.3
|
||||||
|
|
||||||
@@ -0,0 +1,30 @@
|
|||||||
|
From 245427d207ee88a4ba26a66c3de350bcbcc036f2 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Ronald Oussoren <ronaldoussoren@mac.com>
|
||||||
|
Date: Sat, 14 Nov 2020 16:07:47 +0100
|
||||||
|
Subject: [PATCH] bpo-42351: Avoid error when opening header with non-UTF8
|
||||||
|
encoding (GH-23279)
|
||||||
|
|
||||||
|
grep_headers_for() would error out when a header contained
|
||||||
|
text that cannot be interpreted as UTF-8.
|
||||||
|
|
||||||
|
cherry-picked from 7a27c7ed4b by Pedro Fonini <fonini@ip.tv>
|
||||||
|
---
|
||||||
|
setup.py | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/setup.py b/setup.py
|
||||||
|
index f211989aac..467362813d 100644
|
||||||
|
--- a/setup.py
|
||||||
|
+++ b/setup.py
|
||||||
|
@@ -159,7 +159,7 @@ def is_macosx_sdk_path(path):
|
||||||
|
|
||||||
|
def grep_headers_for(function, headers):
|
||||||
|
for header in headers:
|
||||||
|
- with open(header, 'r') as f:
|
||||||
|
+ with open(header, 'r', errors='surrogateescape') as f:
|
||||||
|
if function in f.read():
|
||||||
|
return True
|
||||||
|
return False
|
||||||
|
--
|
||||||
|
2.34.1
|
||||||
|
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
diff --git a/test/v3ext.c b/test/v3ext.c
|
||||||
|
index 7a240cd706..6cec6f1a9b 100644
|
||||||
|
--- a/test/v3ext.c
|
||||||
|
+++ b/test/v3ext.c
|
||||||
|
@@ -15,6 +15,7 @@
|
||||||
|
#include <openssl/err.h>
|
||||||
|
#include "internal/nelem.h"
|
||||||
|
|
||||||
|
+#include <string.h>
|
||||||
|
#include "testutil.h"
|
||||||
|
|
||||||
|
static const char *infile;
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
diff --git a/test/v3ext.c b/test/v3ext.c
|
||||||
|
index 7a240cd706..6cec6f1a9b 100644
|
||||||
|
--- a/test/v3ext.c
|
||||||
|
+++ b/test/v3ext.c
|
||||||
|
@@ -15,6 +15,7 @@
|
||||||
|
#include <openssl/err.h>
|
||||||
|
#include "internal/nelem.h"
|
||||||
|
|
||||||
|
+#include <string.h>
|
||||||
|
#include "testutil.h"
|
||||||
|
|
||||||
|
static const char *infile;
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
diff --git a/test/v3ext.c b/test/v3ext.c
|
||||||
|
index 7a240cd706..6cec6f1a9b 100644
|
||||||
|
--- a/test/v3ext.c
|
||||||
|
+++ b/test/v3ext.c
|
||||||
|
@@ -15,6 +15,7 @@
|
||||||
|
#include <openssl/err.h>
|
||||||
|
#include "internal/nelem.h"
|
||||||
|
|
||||||
|
+#include <string.h>
|
||||||
|
#include "testutil.h"
|
||||||
|
|
||||||
|
static const char *infile;
|
||||||
81
plugins/python-build/share/python-build/pypy2.7-7.3.10
Normal file
81
plugins/python-build/share/python-build/pypy2.7-7.3.10
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
VERSION='7.3.10'
|
||||||
|
PYVER='2.7'
|
||||||
|
|
||||||
|
# https://www.pypy.org/checksums.html
|
||||||
|
aarch64_hash=274342f0e75e99d60ba7a0cfb0e13792e7664163e01450d2f7f2f7825603a0ae
|
||||||
|
linux32_hash=0b17132f62d2a0c3c4572c57eb53820f25611afad71f3d6a310202942baed6e1
|
||||||
|
linux64_hash=461fb6df524208af9e94ffb16989f628b585bdb4b9e97d81e668899fc3a064a3
|
||||||
|
osarm64_hash=14b178f005603e3df6db7574b77b9c65ae79feda1a629214cafcb4eee7da679d
|
||||||
|
osx64_hash=188551185ee945d5e42a3a619205d02ac31db77bdd5d98b6c11469e125c3bdb5
|
||||||
|
s390x_hash=0fac1ec1e05c70941f758be05d40ce7ffe6a42c0416e70b55d40a7523e3e70ae
|
||||||
|
|
||||||
|
### end of manual settings - following lines same for every download
|
||||||
|
|
||||||
|
function err_no_binary {
|
||||||
|
local archmsg="${1}"
|
||||||
|
local ver="pypy${PYVER}-v${VERSION}-src"
|
||||||
|
local url="https://downloads.python.org/pypy/${ver}.tar.bz2"
|
||||||
|
{ echo
|
||||||
|
colorize 1 "ERROR"
|
||||||
|
echo ": The binary distribution of PyPy is not available for ${archmsg}."
|
||||||
|
echo "try '${url}' to build from source."
|
||||||
|
echo
|
||||||
|
} >&2
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
function pypy_pkg_data {
|
||||||
|
# pypy architecture tag
|
||||||
|
local ARCH="${1}"
|
||||||
|
|
||||||
|
# defaults
|
||||||
|
local cmd='install_package' # use bz2
|
||||||
|
local pkg="${ARCH}" # assume matches
|
||||||
|
local ext='tar.bz2'
|
||||||
|
local hash='' # undefined
|
||||||
|
|
||||||
|
# select the hash, fix pkg if not match ARCH
|
||||||
|
case "${ARCH}" in
|
||||||
|
'linux-aarch64' )
|
||||||
|
hash="${aarch64_hash}"
|
||||||
|
pkg='aarch64'
|
||||||
|
;;
|
||||||
|
'linux' )
|
||||||
|
hash="${linux32_hash}"
|
||||||
|
pkg='linux32'
|
||||||
|
;;
|
||||||
|
'linux64' )
|
||||||
|
hash="${linux64_hash}"
|
||||||
|
;;
|
||||||
|
'osarm64' )
|
||||||
|
hash="${osarm64_hash}"
|
||||||
|
pkg='macos_arm64'
|
||||||
|
;;
|
||||||
|
'osx64' )
|
||||||
|
if require_osx_version "10.13"; then
|
||||||
|
hash="${osx64_hash}"
|
||||||
|
pkg='macos_x86_64'
|
||||||
|
else
|
||||||
|
err_no_binary "${ARCH}, OS X < 10.13"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
's390x' )
|
||||||
|
hash="${s390x_hash}"
|
||||||
|
;;
|
||||||
|
* )
|
||||||
|
err_no_binary "${ARCH}"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
local basever="pypy${PYVER}-v${VERSION}"
|
||||||
|
local baseurl="https://downloads.python.org/pypy/${basever}"
|
||||||
|
|
||||||
|
# result - command, package dir, url+hash
|
||||||
|
echo "${cmd}" "${basever}-${pkg}" "${baseurl}-${pkg}.${ext}#${hash}"
|
||||||
|
}
|
||||||
|
|
||||||
|
# determine command, package directory, url+hash
|
||||||
|
declare -a pd="$(pypy_pkg_data "$(pypy_architecture 2>/dev/null || true)")"
|
||||||
|
|
||||||
|
# install
|
||||||
|
${pd[0]} "${pd[1]}" "${pd[2]}" 'pypy' "verify_py${PYVER//./}" 'ensurepip'
|
||||||
14
plugins/python-build/share/python-build/pypy2.7-7.3.10-src
Normal file
14
plugins/python-build/share/python-build/pypy2.7-7.3.10-src
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
VERSION='7.3.10'
|
||||||
|
PYVER='2.7'
|
||||||
|
|
||||||
|
# https://www.pypy.org/checksums.html
|
||||||
|
hash=35e2cf4519cb51c4d5ffb4493ee24f0c7f42b4b04944903ca4b33981a04a3bc5
|
||||||
|
|
||||||
|
### end of manual settings - following lines same for every download
|
||||||
|
|
||||||
|
ver="pypy${PYVER}-v${VERSION}-src"
|
||||||
|
url="https://downloads.python.org/pypy/${ver}.tar.bz2"
|
||||||
|
|
||||||
|
prefer_openssl11
|
||||||
|
install_package "openssl-1.1.1f" "https://www.openssl.org/source/openssl-1.1.1f.tar.gz#186c6bfe6ecfba7a5b48c47f8a1673d0f3b0e5ba2e25602dd23b629975da3f35" mac_openssl --if has_broken_mac_openssl
|
||||||
|
install_package "${ver}" "${url}#${hash}" 'pypy_builder' "verify_py${PYVER//./}" 'ensurepip'
|
||||||
@@ -11,29 +11,38 @@ win64_hash=ca7b0f4c576995b388cfb4c796e3f6f20b037e5314571bf267daa068a3a2af31
|
|||||||
|
|
||||||
### end of manual settings - following lines same for every download
|
### end of manual settings - following lines same for every download
|
||||||
|
|
||||||
function pypy_pkg_data {
|
function err_no_binary {
|
||||||
# pypy architecture
|
local archmsg="${1}"
|
||||||
local ARCH="${1}"
|
local ver="pypy${PYVER}-v${VERSION}-src"
|
||||||
|
local url="https://downloads.python.org/pypy/${ver}.tar.bz2"
|
||||||
|
{ echo
|
||||||
|
colorize 1 "ERROR"
|
||||||
|
echo ": The binary distribution of PyPy is not available for ${archmsg}."
|
||||||
|
echo "try '${url}' to build from source."
|
||||||
|
echo
|
||||||
|
} >&2
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
local basesrc="pypy${PYVER}-${VERSION}-src"
|
function pypy_pkg_data {
|
||||||
local basever="pypy${PYVER}-v${VERSION}"
|
# pypy architecture tag
|
||||||
local baseurl="https://downloads.python.org/pypy/${basever}"
|
local ARCH="${1}"
|
||||||
|
|
||||||
# defaults
|
# defaults
|
||||||
local cmd='install_package' # use bz2
|
local cmd='install_package' # use bz2
|
||||||
local pkg="${ARCH}" # assume matches
|
local pkg="${ARCH}" # assume matches
|
||||||
local url="${baseurl}-${pkg}.tar.bz2" # use bz2
|
local ext='tar.bz2' # windows is always diff...
|
||||||
local hash='' # undefined
|
local hash='' # undefined
|
||||||
|
|
||||||
case "${pkg}" in
|
# select the hash, fix pkg if not match ARCH, windows has ext of zip
|
||||||
|
case "${ARCH}" in
|
||||||
'linux-aarch64' )
|
'linux-aarch64' )
|
||||||
hash="${aarch64_hash}"
|
hash="${aarch64_hash}"
|
||||||
url="${baseurl}-aarch64.tar.bz2" # diff url
|
pkg='aarch64'
|
||||||
;;
|
;;
|
||||||
'linux' )
|
'linux' )
|
||||||
hash="${linux32_hash}"
|
hash="${linux32_hash}"
|
||||||
pkg='linux32' # package name revised
|
pkg='linux32'
|
||||||
url="${baseurl}-${pkg}.tar.bz2" # new url
|
|
||||||
;;
|
;;
|
||||||
'linux64' )
|
'linux64' )
|
||||||
hash="${linux64_hash}"
|
hash="${linux64_hash}"
|
||||||
@@ -42,13 +51,7 @@ function pypy_pkg_data {
|
|||||||
if require_osx_version "10.13"; then
|
if require_osx_version "10.13"; then
|
||||||
hash="${osx64_hash}"
|
hash="${osx64_hash}"
|
||||||
else
|
else
|
||||||
{ echo
|
err_no_binary "${ARCH}, OS X < 10.13"
|
||||||
colorize 1 "ERROR"
|
|
||||||
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true), OS X < 10.13."
|
|
||||||
echo "try '${basesrc}' to build from source."
|
|
||||||
echo
|
|
||||||
} >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
's390x' )
|
's390x' )
|
||||||
@@ -57,21 +60,18 @@ function pypy_pkg_data {
|
|||||||
'win64' )
|
'win64' )
|
||||||
hash="${win64_hash}"
|
hash="${win64_hash}"
|
||||||
cmd='install_zip' # diff command
|
cmd='install_zip' # diff command
|
||||||
url="${baseurl}-${pkg}.zip" # zip rather than bz2
|
ext='zip' # zip rather than bz2
|
||||||
;;
|
;;
|
||||||
* )
|
* )
|
||||||
{ echo
|
err_no_binary "${ARCH}"
|
||||||
colorize 1 "ERROR"
|
|
||||||
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
|
|
||||||
echo "try '${basesrc}' to build from source."
|
|
||||||
echo
|
|
||||||
} >&2
|
|
||||||
exit 1
|
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
local basever="pypy${PYVER}-v${VERSION}"
|
||||||
|
local baseurl="https://downloads.python.org/pypy/${basever}"
|
||||||
|
|
||||||
# result - command, package dir, url+hash
|
# result - command, package dir, url+hash
|
||||||
echo "${cmd}" "${basever}-${pkg}" "${url}#${hash}"
|
echo "${cmd}" "${basever}-${pkg}" "${baseurl}-${pkg}.${ext}#${hash}"
|
||||||
}
|
}
|
||||||
|
|
||||||
# determine command, package directory, url+hash
|
# determine command, package directory, url+hash
|
||||||
|
|||||||
@@ -11,29 +11,38 @@ win64_hash=8acb184b48fb3c854de0662e4d23a66b90e73b1ab73a86695022c12c745d8b00
|
|||||||
|
|
||||||
### end of manual settings - following lines same for every download
|
### end of manual settings - following lines same for every download
|
||||||
|
|
||||||
function pypy_pkg_data {
|
function err_no_binary {
|
||||||
# pypy architecture
|
local archmsg="${1}"
|
||||||
local ARCH="${1}"
|
local ver="pypy${PYVER}-v${VERSION}-src"
|
||||||
|
local url="https://downloads.python.org/pypy/${ver}.tar.bz2"
|
||||||
|
{ echo
|
||||||
|
colorize 1 "ERROR"
|
||||||
|
echo ": The binary distribution of PyPy is not available for ${archmsg}."
|
||||||
|
echo "try '${url}' to build from source."
|
||||||
|
echo
|
||||||
|
} >&2
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
local basesrc="pypy${PYVER}-${VERSION}-src"
|
function pypy_pkg_data {
|
||||||
local basever="pypy${PYVER}-v${VERSION}"
|
# pypy architecture tag
|
||||||
local baseurl="https://downloads.python.org/pypy/${basever}"
|
local ARCH="${1}"
|
||||||
|
|
||||||
# defaults
|
# defaults
|
||||||
local cmd='install_package' # use bz2
|
local cmd='install_package' # use bz2
|
||||||
local pkg="${ARCH}" # assume matches
|
local pkg="${ARCH}" # assume matches
|
||||||
local url="${baseurl}-${pkg}.tar.bz2" # use bz2
|
local ext='tar.bz2' # windows is always diff...
|
||||||
local hash='' # undefined
|
local hash='' # undefined
|
||||||
|
|
||||||
case "${pkg}" in
|
# select the hash, fix pkg if not match ARCH, windows has ext of zip
|
||||||
|
case "${ARCH}" in
|
||||||
'linux-aarch64' )
|
'linux-aarch64' )
|
||||||
hash="${aarch64_hash}"
|
hash="${aarch64_hash}"
|
||||||
url="${baseurl}-aarch64.tar.bz2" # diff url
|
pkg='aarch64'
|
||||||
;;
|
;;
|
||||||
'linux' )
|
'linux' )
|
||||||
hash="${linux32_hash}"
|
hash="${linux32_hash}"
|
||||||
pkg='linux32' # package name revised
|
pkg='linux32'
|
||||||
url="${baseurl}-${pkg}.tar.bz2" # new url
|
|
||||||
;;
|
;;
|
||||||
'linux64' )
|
'linux64' )
|
||||||
hash="${linux64_hash}"
|
hash="${linux64_hash}"
|
||||||
@@ -42,13 +51,7 @@ function pypy_pkg_data {
|
|||||||
if require_osx_version "10.13"; then
|
if require_osx_version "10.13"; then
|
||||||
hash="${osx64_hash}"
|
hash="${osx64_hash}"
|
||||||
else
|
else
|
||||||
{ echo
|
err_no_binary "${ARCH}, OS X < 10.13"
|
||||||
colorize 1 "ERROR"
|
|
||||||
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true), OS X < 10.13."
|
|
||||||
echo "try '${basesrc}' to build from source."
|
|
||||||
echo
|
|
||||||
} >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
's390x' )
|
's390x' )
|
||||||
@@ -57,21 +60,18 @@ function pypy_pkg_data {
|
|||||||
'win64' )
|
'win64' )
|
||||||
hash="${win64_hash}"
|
hash="${win64_hash}"
|
||||||
cmd='install_zip' # diff command
|
cmd='install_zip' # diff command
|
||||||
url="${baseurl}-${pkg}.zip" # zip rather than bz2
|
ext='zip' # zip rather than bz2
|
||||||
;;
|
;;
|
||||||
* )
|
* )
|
||||||
{ echo
|
err_no_binary "${ARCH}"
|
||||||
colorize 1 "ERROR"
|
|
||||||
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
|
|
||||||
echo "try '${basesrc}' to build from source."
|
|
||||||
echo
|
|
||||||
} >&2
|
|
||||||
exit 1
|
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
local basever="pypy${PYVER}-v${VERSION}"
|
||||||
|
local baseurl="https://downloads.python.org/pypy/${basever}"
|
||||||
|
|
||||||
# result - command, package dir, url+hash
|
# result - command, package dir, url+hash
|
||||||
echo "${cmd}" "${basever}-${pkg}" "${url}#${hash}"
|
echo "${cmd}" "${basever}-${pkg}" "${baseurl}-${pkg}.${ext}#${hash}"
|
||||||
}
|
}
|
||||||
|
|
||||||
# determine command, package directory, url+hash
|
# determine command, package directory, url+hash
|
||||||
|
|||||||
81
plugins/python-build/share/python-build/pypy3.8-7.3.10
Normal file
81
plugins/python-build/share/python-build/pypy3.8-7.3.10
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
VERSION='7.3.10'
|
||||||
|
PYVER='3.8'
|
||||||
|
|
||||||
|
# https://www.pypy.org/checksums.html
|
||||||
|
aarch64_hash=e4caa1a545f22cfee87d5b9aa6f8852347f223643ad7d2562e0b2a2f4663ad98
|
||||||
|
linux32_hash=b70ed7fdc73a74ebdc04f07439f7bad1a849aaca95e26b4a74049d0e483f071c
|
||||||
|
linux64_hash=ceef6496fd4ab1c99e3ec22ce657b8f10f8bb77a32427fadfb5e1dd943806011
|
||||||
|
osarm64_hash=6cb1429371e4854b718148a509d80143f801e3abfc72fef58d88aeeee1e98f9e
|
||||||
|
osx64_hash=399eb1ce4c65f62f6a096b7c273536601b7695e3c0dc0457393a659b95b7615b
|
||||||
|
s390x_hash=c294f8e815158388628fe77ac5b8ad6cd93c8db1359091fa02d41cf6da4d61a1
|
||||||
|
|
||||||
|
### end of manual settings - following lines same for every download
|
||||||
|
|
||||||
|
function err_no_binary {
|
||||||
|
local archmsg="${1}"
|
||||||
|
local ver="pypy${PYVER}-v${VERSION}-src"
|
||||||
|
local url="https://downloads.python.org/pypy/${ver}.tar.bz2"
|
||||||
|
{ echo
|
||||||
|
colorize 1 "ERROR"
|
||||||
|
echo ": The binary distribution of PyPy is not available for ${archmsg}."
|
||||||
|
echo "try '${url}' to build from source."
|
||||||
|
echo
|
||||||
|
} >&2
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
function pypy_pkg_data {
|
||||||
|
# pypy architecture tag
|
||||||
|
local ARCH="${1}"
|
||||||
|
|
||||||
|
# defaults
|
||||||
|
local cmd='install_package' # use bz2
|
||||||
|
local pkg="${ARCH}" # assume matches
|
||||||
|
local ext='tar.bz2'
|
||||||
|
local hash='' # undefined
|
||||||
|
|
||||||
|
# select the hash, fix pkg if not match ARCH
|
||||||
|
case "${ARCH}" in
|
||||||
|
'linux-aarch64' )
|
||||||
|
hash="${aarch64_hash}"
|
||||||
|
pkg='aarch64'
|
||||||
|
;;
|
||||||
|
'linux' )
|
||||||
|
hash="${linux32_hash}"
|
||||||
|
pkg='linux32'
|
||||||
|
;;
|
||||||
|
'linux64' )
|
||||||
|
hash="${linux64_hash}"
|
||||||
|
;;
|
||||||
|
'osarm64' )
|
||||||
|
hash="${osarm64_hash}"
|
||||||
|
pkg='macos_arm64'
|
||||||
|
;;
|
||||||
|
'osx64' )
|
||||||
|
if require_osx_version "10.13"; then
|
||||||
|
hash="${osx64_hash}"
|
||||||
|
pkg='macos_x86_64'
|
||||||
|
else
|
||||||
|
err_no_binary "${ARCH}, OS X < 10.13"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
's390x' )
|
||||||
|
hash="${s390x_hash}"
|
||||||
|
;;
|
||||||
|
* )
|
||||||
|
err_no_binary "${ARCH}"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
local basever="pypy${PYVER}-v${VERSION}"
|
||||||
|
local baseurl="https://downloads.python.org/pypy/${basever}"
|
||||||
|
|
||||||
|
# result - command, package dir, url+hash
|
||||||
|
echo "${cmd}" "${basever}-${pkg}" "${baseurl}-${pkg}.${ext}#${hash}"
|
||||||
|
}
|
||||||
|
|
||||||
|
# determine command, package directory, url+hash
|
||||||
|
declare -a pd="$(pypy_pkg_data "$(pypy_architecture 2>/dev/null || true)")"
|
||||||
|
|
||||||
|
# install
|
||||||
|
${pd[0]} "${pd[1]}" "${pd[2]}" 'pypy' "verify_py${PYVER//./}" 'ensurepip'
|
||||||
14
plugins/python-build/share/python-build/pypy3.8-7.3.10-src
Normal file
14
plugins/python-build/share/python-build/pypy3.8-7.3.10-src
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
VERSION='7.3.10'
|
||||||
|
PYVER='3.8'
|
||||||
|
|
||||||
|
# https://www.pypy.org/checksums.html
|
||||||
|
hash=218a1e062f17aba89f61bc398e8498f13c048b9fcf294343f5d9d56c3ac9b882
|
||||||
|
|
||||||
|
### end of manual settings - following lines same for every download
|
||||||
|
|
||||||
|
ver="pypy${PYVER}-v${VERSION}-src"
|
||||||
|
url="https://downloads.python.org/pypy/${ver}.tar.bz2"
|
||||||
|
|
||||||
|
prefer_openssl11
|
||||||
|
install_package "openssl-1.1.1f" "https://www.openssl.org/source/openssl-1.1.1f.tar.gz#186c6bfe6ecfba7a5b48c47f8a1673d0f3b0e5ba2e25602dd23b629975da3f35" mac_openssl --if has_broken_mac_openssl
|
||||||
|
install_package "${ver}" "${url}#${hash}" 'pypy_builder' "verify_py${PYVER//./}" 'ensurepip'
|
||||||
@@ -11,29 +11,38 @@ win64_hash=05022baaa55db2b60880f2422312d9e4025e1267303ac57f33e8253559d0be88
|
|||||||
|
|
||||||
### end of manual settings - following lines same for every download
|
### end of manual settings - following lines same for every download
|
||||||
|
|
||||||
function pypy_pkg_data {
|
function err_no_binary {
|
||||||
# pypy architecture
|
local archmsg="${1}"
|
||||||
local ARCH="${1}"
|
local ver="pypy${PYVER}-v${VERSION}-src"
|
||||||
|
local url="https://downloads.python.org/pypy/${ver}.tar.bz2"
|
||||||
|
{ echo
|
||||||
|
colorize 1 "ERROR"
|
||||||
|
echo ": The binary distribution of PyPy is not available for ${archmsg}."
|
||||||
|
echo "try '${url}' to build from source."
|
||||||
|
echo
|
||||||
|
} >&2
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
local basesrc="pypy${PYVER}-${VERSION}-src"
|
function pypy_pkg_data {
|
||||||
local basever="pypy${PYVER}-v${VERSION}"
|
# pypy architecture tag
|
||||||
local baseurl="https://downloads.python.org/pypy/${basever}"
|
local ARCH="${1}"
|
||||||
|
|
||||||
# defaults
|
# defaults
|
||||||
local cmd='install_package' # use bz2
|
local cmd='install_package' # use bz2
|
||||||
local pkg="${ARCH}" # assume matches
|
local pkg="${ARCH}" # assume matches
|
||||||
local url="${baseurl}-${pkg}.tar.bz2" # use bz2
|
local ext='tar.bz2' # windows is always diff...
|
||||||
local hash='' # undefined
|
local hash='' # undefined
|
||||||
|
|
||||||
case "${pkg}" in
|
# select the hash, fix pkg if not match ARCH, windows has ext of zip
|
||||||
|
case "${ARCH}" in
|
||||||
'linux-aarch64' )
|
'linux-aarch64' )
|
||||||
hash="${aarch64_hash}"
|
hash="${aarch64_hash}"
|
||||||
url="${baseurl}-aarch64.tar.bz2" # diff url
|
pkg='aarch64'
|
||||||
;;
|
;;
|
||||||
'linux' )
|
'linux' )
|
||||||
hash="${linux32_hash}"
|
hash="${linux32_hash}"
|
||||||
pkg='linux32' # package name revised
|
pkg='linux32'
|
||||||
url="${baseurl}-${pkg}.tar.bz2" # new url
|
|
||||||
;;
|
;;
|
||||||
'linux64' )
|
'linux64' )
|
||||||
hash="${linux64_hash}"
|
hash="${linux64_hash}"
|
||||||
@@ -42,13 +51,7 @@ function pypy_pkg_data {
|
|||||||
if require_osx_version "10.13"; then
|
if require_osx_version "10.13"; then
|
||||||
hash="${osx64_hash}"
|
hash="${osx64_hash}"
|
||||||
else
|
else
|
||||||
{ echo
|
err_no_binary "${ARCH}, OS X < 10.13"
|
||||||
colorize 1 "ERROR"
|
|
||||||
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true), OS X < 10.13."
|
|
||||||
echo "try '${basesrc}' to build from source."
|
|
||||||
echo
|
|
||||||
} >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
's390x' )
|
's390x' )
|
||||||
@@ -57,21 +60,18 @@ function pypy_pkg_data {
|
|||||||
'win64' )
|
'win64' )
|
||||||
hash="${win64_hash}"
|
hash="${win64_hash}"
|
||||||
cmd='install_zip' # diff command
|
cmd='install_zip' # diff command
|
||||||
url="${baseurl}-${pkg}.zip" # zip rather than bz2
|
ext='zip' # zip rather than bz2
|
||||||
;;
|
;;
|
||||||
* )
|
* )
|
||||||
{ echo
|
err_no_binary "${ARCH}"
|
||||||
colorize 1 "ERROR"
|
|
||||||
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
|
|
||||||
echo "try '${basesrc}' to build from source."
|
|
||||||
echo
|
|
||||||
} >&2
|
|
||||||
exit 1
|
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
local basever="pypy${PYVER}-v${VERSION}"
|
||||||
|
local baseurl="https://downloads.python.org/pypy/${basever}"
|
||||||
|
|
||||||
# result - command, package dir, url+hash
|
# result - command, package dir, url+hash
|
||||||
echo "${cmd}" "${basever}-${pkg}" "${url}#${hash}"
|
echo "${cmd}" "${basever}-${pkg}" "${baseurl}-${pkg}.${ext}#${hash}"
|
||||||
}
|
}
|
||||||
|
|
||||||
# determine command, package directory, url+hash
|
# determine command, package directory, url+hash
|
||||||
|
|||||||
81
plugins/python-build/share/python-build/pypy3.9-7.3.10
Normal file
81
plugins/python-build/share/python-build/pypy3.9-7.3.10
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
VERSION='7.3.10'
|
||||||
|
PYVER='3.9'
|
||||||
|
|
||||||
|
# https://www.pypy.org/checksums.html
|
||||||
|
aarch64_hash=657a04fd9a5a992a2f116a9e7e9132ea0c578721f59139c9fb2083775f71e514
|
||||||
|
linux32_hash=b6db59613b9a1c0c1ab87bc103f52ee95193423882dc8a848b68850b8ba59cc5
|
||||||
|
linux64_hash=95cf99406179460d63ddbfe1ec870f889d05f7767ce81cef14b88a3a9e127266
|
||||||
|
osarm64_hash=e2a6bec7408e6497c7de8165aa4a1b15e2416aec4a72f2578f793fb06859ccba
|
||||||
|
osx64_hash=f90c8619b41e68ec9ffd7d5e913fe02e60843da43d3735b1c1bc75bcfe638d97
|
||||||
|
s390x_hash=ca6525a540cf0c682d1592ae35d3fbc97559a97260e4b789255cc76dde7a14f0
|
||||||
|
|
||||||
|
### end of manual settings - following lines same for every download
|
||||||
|
|
||||||
|
function err_no_binary {
|
||||||
|
local archmsg="${1}"
|
||||||
|
local ver="pypy${PYVER}-v${VERSION}-src"
|
||||||
|
local url="https://downloads.python.org/pypy/${ver}.tar.bz2"
|
||||||
|
{ echo
|
||||||
|
colorize 1 "ERROR"
|
||||||
|
echo ": The binary distribution of PyPy is not available for ${archmsg}."
|
||||||
|
echo "try '${url}' to build from source."
|
||||||
|
echo
|
||||||
|
} >&2
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
function pypy_pkg_data {
|
||||||
|
# pypy architecture tag
|
||||||
|
local ARCH="${1}"
|
||||||
|
|
||||||
|
# defaults
|
||||||
|
local cmd='install_package' # use bz2
|
||||||
|
local pkg="${ARCH}" # assume matches
|
||||||
|
local ext='tar.bz2'
|
||||||
|
local hash='' # undefined
|
||||||
|
|
||||||
|
# select the hash, fix pkg if not match ARCH
|
||||||
|
case "${ARCH}" in
|
||||||
|
'linux-aarch64' )
|
||||||
|
hash="${aarch64_hash}"
|
||||||
|
pkg='aarch64'
|
||||||
|
;;
|
||||||
|
'linux' )
|
||||||
|
hash="${linux32_hash}"
|
||||||
|
pkg='linux32'
|
||||||
|
;;
|
||||||
|
'linux64' )
|
||||||
|
hash="${linux64_hash}"
|
||||||
|
;;
|
||||||
|
'osarm64' )
|
||||||
|
hash="${osarm64_hash}"
|
||||||
|
pkg='macos_arm64'
|
||||||
|
;;
|
||||||
|
'osx64' )
|
||||||
|
if require_osx_version "10.13"; then
|
||||||
|
hash="${osx64_hash}"
|
||||||
|
pkg='macos_x86_64'
|
||||||
|
else
|
||||||
|
err_no_binary "${ARCH}, OS X < 10.13"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
's390x' )
|
||||||
|
hash="${s390x_hash}"
|
||||||
|
;;
|
||||||
|
* )
|
||||||
|
err_no_binary "${ARCH}"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
local basever="pypy${PYVER}-v${VERSION}"
|
||||||
|
local baseurl="https://downloads.python.org/pypy/${basever}"
|
||||||
|
|
||||||
|
# result - command, package dir, url+hash
|
||||||
|
echo "${cmd}" "${basever}-${pkg}" "${baseurl}-${pkg}.${ext}#${hash}"
|
||||||
|
}
|
||||||
|
|
||||||
|
# determine command, package directory, url+hash
|
||||||
|
declare -a pd="$(pypy_pkg_data "$(pypy_architecture 2>/dev/null || true)")"
|
||||||
|
|
||||||
|
# install
|
||||||
|
${pd[0]} "${pd[1]}" "${pd[2]}" 'pypy' "verify_py${PYVER//./}" 'ensurepip'
|
||||||
14
plugins/python-build/share/python-build/pypy3.9-7.3.10-src
Normal file
14
plugins/python-build/share/python-build/pypy3.9-7.3.10-src
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
VERSION='7.3.10'
|
||||||
|
PYVER='3.9'
|
||||||
|
|
||||||
|
# https://www.pypy.org/checksums.html
|
||||||
|
hash=3738d32575ed2513e3e66878e4e4c6c208caed267570f3f9f814748830002967
|
||||||
|
|
||||||
|
### end of manual settings - following lines same for every download
|
||||||
|
|
||||||
|
ver="pypy${PYVER}-v${VERSION}-src"
|
||||||
|
url="https://downloads.python.org/pypy/${ver}.tar.bz2"
|
||||||
|
|
||||||
|
prefer_openssl11
|
||||||
|
install_package "openssl-1.1.1f" "https://www.openssl.org/source/openssl-1.1.1f.tar.gz#186c6bfe6ecfba7a5b48c47f8a1673d0f3b0e5ba2e25602dd23b629975da3f35" mac_openssl --if has_broken_mac_openssl
|
||||||
|
install_package "${ver}" "${url}#${hash}" 'pypy_builder' "verify_py${PYVER//./}" 'ensurepip'
|
||||||
@@ -11,29 +11,38 @@ win64_hash=be48ab42f95c402543a7042c999c9433b17e55477c847612c8733a583ca6dff5
|
|||||||
|
|
||||||
### end of manual settings - following lines same for every download
|
### end of manual settings - following lines same for every download
|
||||||
|
|
||||||
function pypy_pkg_data {
|
function err_no_binary {
|
||||||
# pypy architecture
|
local archmsg="${1}"
|
||||||
local ARCH="${1}"
|
local ver="pypy${PYVER}-v${VERSION}-src"
|
||||||
|
local url="https://downloads.python.org/pypy/${ver}.tar.bz2"
|
||||||
|
{ echo
|
||||||
|
colorize 1 "ERROR"
|
||||||
|
echo ": The binary distribution of PyPy is not available for ${archmsg}."
|
||||||
|
echo "try '${url}' to build from source."
|
||||||
|
echo
|
||||||
|
} >&2
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
local basesrc="pypy${PYVER}-${VERSION}-src"
|
function pypy_pkg_data {
|
||||||
local basever="pypy${PYVER}-v${VERSION}"
|
# pypy architecture tag
|
||||||
local baseurl="https://downloads.python.org/pypy/${basever}"
|
local ARCH="${1}"
|
||||||
|
|
||||||
# defaults
|
# defaults
|
||||||
local cmd='install_package' # use bz2
|
local cmd='install_package' # use bz2
|
||||||
local pkg="${ARCH}" # assume matches
|
local pkg="${ARCH}" # assume matches
|
||||||
local url="${baseurl}-${pkg}.tar.bz2" # use bz2
|
local ext='tar.bz2' # windows is always diff...
|
||||||
local hash='' # undefined
|
local hash='' # undefined
|
||||||
|
|
||||||
case "${pkg}" in
|
# select the hash, fix pkg if not match ARCH, windows has ext of zip
|
||||||
|
case "${ARCH}" in
|
||||||
'linux-aarch64' )
|
'linux-aarch64' )
|
||||||
hash="${aarch64_hash}"
|
hash="${aarch64_hash}"
|
||||||
url="${baseurl}-aarch64.tar.bz2" # diff url
|
pkg='aarch64'
|
||||||
;;
|
;;
|
||||||
'linux' )
|
'linux' )
|
||||||
hash="${linux32_hash}"
|
hash="${linux32_hash}"
|
||||||
pkg='linux32' # package name revised
|
pkg='linux32'
|
||||||
url="${baseurl}-${pkg}.tar.bz2" # new url
|
|
||||||
;;
|
;;
|
||||||
'linux64' )
|
'linux64' )
|
||||||
hash="${linux64_hash}"
|
hash="${linux64_hash}"
|
||||||
@@ -42,13 +51,7 @@ function pypy_pkg_data {
|
|||||||
if require_osx_version "10.13"; then
|
if require_osx_version "10.13"; then
|
||||||
hash="${osx64_hash}"
|
hash="${osx64_hash}"
|
||||||
else
|
else
|
||||||
{ echo
|
err_no_binary "${ARCH}, OS X < 10.13"
|
||||||
colorize 1 "ERROR"
|
|
||||||
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true), OS X < 10.13."
|
|
||||||
echo "try '${basesrc}' to build from source."
|
|
||||||
echo
|
|
||||||
} >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
's390x' )
|
's390x' )
|
||||||
@@ -57,21 +60,18 @@ function pypy_pkg_data {
|
|||||||
'win64' )
|
'win64' )
|
||||||
hash="${win64_hash}"
|
hash="${win64_hash}"
|
||||||
cmd='install_zip' # diff command
|
cmd='install_zip' # diff command
|
||||||
url="${baseurl}-${pkg}.zip" # zip rather than bz2
|
ext='zip' # zip rather than bz2
|
||||||
;;
|
;;
|
||||||
* )
|
* )
|
||||||
{ echo
|
err_no_binary "${ARCH}"
|
||||||
colorize 1 "ERROR"
|
|
||||||
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
|
|
||||||
echo "try '${basesrc}' to build from source."
|
|
||||||
echo
|
|
||||||
} >&2
|
|
||||||
exit 1
|
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
local basever="pypy${PYVER}-v${VERSION}"
|
||||||
|
local baseurl="https://downloads.python.org/pypy/${basever}"
|
||||||
|
|
||||||
# result - command, package dir, url+hash
|
# result - command, package dir, url+hash
|
||||||
echo "${cmd}" "${basever}-${pkg}" "${url}#${hash}"
|
echo "${cmd}" "${basever}-${pkg}" "${baseurl}-${pkg}.${ext}#${hash}"
|
||||||
}
|
}
|
||||||
|
|
||||||
# determine command, package directory, url+hash
|
# determine command, package directory, url+hash
|
||||||
|
|||||||
Reference in New Issue
Block a user