From 4cf0116a7bbe300e199a0565ebf6656af61352c6 Mon Sep 17 00:00:00 2001 From: Docker Library Bot Date: Wed, 7 May 2025 08:49:39 -0700 Subject: [PATCH 1/3] Update 3.14-rc to 3.14.0b1 --- 3.14-rc/alpine3.20/Dockerfile | 4 ++-- 3.14-rc/alpine3.21/Dockerfile | 4 ++-- 3.14-rc/bookworm/Dockerfile | 4 ++-- 3.14-rc/bullseye/Dockerfile | 4 ++-- 3.14-rc/slim-bookworm/Dockerfile | 4 ++-- 3.14-rc/slim-bullseye/Dockerfile | 4 ++-- 3.14-rc/windows/windowsservercore-1809/Dockerfile | 4 ++-- 3.14-rc/windows/windowsservercore-ltsc2022/Dockerfile | 4 ++-- 3.14-rc/windows/windowsservercore-ltsc2025/Dockerfile | 4 ++-- versions.json | 6 +++--- 10 files changed, 21 insertions(+), 21 deletions(-) diff --git a/3.14-rc/alpine3.20/Dockerfile b/3.14-rc/alpine3.20/Dockerfile index c90a9b7e6..a6bbb3c13 100644 --- a/3.14-rc/alpine3.20/Dockerfile +++ b/3.14-rc/alpine3.20/Dockerfile @@ -16,8 +16,8 @@ RUN set -eux; \ tzdata \ ; -ENV PYTHON_VERSION 3.14.0a7 -ENV PYTHON_SHA256 71adbcec3ac9edf93308e55cfb4184f2eb4b16fda2bb0a5a382929ed29c8386d +ENV PYTHON_VERSION 3.14.0b1 +ENV PYTHON_SHA256 2ddd30a77c9f62e065ce648664a254b9b0c011bcdaa8c1c2787087e644cbeb39 RUN set -eux; \ \ diff --git a/3.14-rc/alpine3.21/Dockerfile b/3.14-rc/alpine3.21/Dockerfile index 667014ebf..a84256a6a 100644 --- a/3.14-rc/alpine3.21/Dockerfile +++ b/3.14-rc/alpine3.21/Dockerfile @@ -16,8 +16,8 @@ RUN set -eux; \ tzdata \ ; -ENV PYTHON_VERSION 3.14.0a7 -ENV PYTHON_SHA256 71adbcec3ac9edf93308e55cfb4184f2eb4b16fda2bb0a5a382929ed29c8386d +ENV PYTHON_VERSION 3.14.0b1 +ENV PYTHON_SHA256 2ddd30a77c9f62e065ce648664a254b9b0c011bcdaa8c1c2787087e644cbeb39 RUN set -eux; \ \ diff --git a/3.14-rc/bookworm/Dockerfile b/3.14-rc/bookworm/Dockerfile index 422f4857f..3770ba0e7 100644 --- a/3.14-rc/bookworm/Dockerfile +++ b/3.14-rc/bookworm/Dockerfile @@ -19,8 +19,8 @@ RUN set -eux; \ ; \ rm -rf /var/lib/apt/lists/* -ENV PYTHON_VERSION 3.14.0a7 -ENV PYTHON_SHA256 71adbcec3ac9edf93308e55cfb4184f2eb4b16fda2bb0a5a382929ed29c8386d +ENV PYTHON_VERSION 3.14.0b1 +ENV PYTHON_SHA256 2ddd30a77c9f62e065ce648664a254b9b0c011bcdaa8c1c2787087e644cbeb39 RUN set -eux; \ \ diff --git a/3.14-rc/bullseye/Dockerfile b/3.14-rc/bullseye/Dockerfile index fa88cc23b..28cb40b2d 100644 --- a/3.14-rc/bullseye/Dockerfile +++ b/3.14-rc/bullseye/Dockerfile @@ -19,8 +19,8 @@ RUN set -eux; \ ; \ rm -rf /var/lib/apt/lists/* -ENV PYTHON_VERSION 3.14.0a7 -ENV PYTHON_SHA256 71adbcec3ac9edf93308e55cfb4184f2eb4b16fda2bb0a5a382929ed29c8386d +ENV PYTHON_VERSION 3.14.0b1 +ENV PYTHON_SHA256 2ddd30a77c9f62e065ce648664a254b9b0c011bcdaa8c1c2787087e644cbeb39 RUN set -eux; \ \ diff --git a/3.14-rc/slim-bookworm/Dockerfile b/3.14-rc/slim-bookworm/Dockerfile index ce1fc8f3d..deae80dd1 100644 --- a/3.14-rc/slim-bookworm/Dockerfile +++ b/3.14-rc/slim-bookworm/Dockerfile @@ -19,8 +19,8 @@ RUN set -eux; \ ; \ rm -rf /var/lib/apt/lists/* -ENV PYTHON_VERSION 3.14.0a7 -ENV PYTHON_SHA256 71adbcec3ac9edf93308e55cfb4184f2eb4b16fda2bb0a5a382929ed29c8386d +ENV PYTHON_VERSION 3.14.0b1 +ENV PYTHON_SHA256 2ddd30a77c9f62e065ce648664a254b9b0c011bcdaa8c1c2787087e644cbeb39 RUN set -eux; \ \ diff --git a/3.14-rc/slim-bullseye/Dockerfile b/3.14-rc/slim-bullseye/Dockerfile index 166362488..0803096ab 100644 --- a/3.14-rc/slim-bullseye/Dockerfile +++ b/3.14-rc/slim-bullseye/Dockerfile @@ -19,8 +19,8 @@ RUN set -eux; \ ; \ rm -rf /var/lib/apt/lists/* -ENV PYTHON_VERSION 3.14.0a7 -ENV PYTHON_SHA256 71adbcec3ac9edf93308e55cfb4184f2eb4b16fda2bb0a5a382929ed29c8386d +ENV PYTHON_VERSION 3.14.0b1 +ENV PYTHON_SHA256 2ddd30a77c9f62e065ce648664a254b9b0c011bcdaa8c1c2787087e644cbeb39 RUN set -eux; \ \ diff --git a/3.14-rc/windows/windowsservercore-1809/Dockerfile b/3.14-rc/windows/windowsservercore-1809/Dockerfile index 74bba95e6..ca6012734 100644 --- a/3.14-rc/windows/windowsservercore-1809/Dockerfile +++ b/3.14-rc/windows/windowsservercore-1809/Dockerfile @@ -11,8 +11,8 @@ SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPref # https://github.com/docker-library/python/pull/557 ENV PYTHONIOENCODING UTF-8 -ENV PYTHON_VERSION 3.14.0a7 -ENV PYTHON_SHA256 944e24cde04e4067ae728578afc8fbc78d9a0d735e9c9348720c857d61bd8e1e +ENV PYTHON_VERSION 3.14.0b1 +ENV PYTHON_SHA256 a878026c12b1a606d02f5bbf3ed65aa780ee8272964b8f95d8348ffa2d6ca096 RUN $url = ('https://www.python.org/ftp/python/{0}/python-{1}-amd64.exe' -f ($env:PYTHON_VERSION -replace '[a-z]+[0-9]*$', ''), $env:PYTHON_VERSION); \ Write-Host ('Downloading {0} ...' -f $url); \ diff --git a/3.14-rc/windows/windowsservercore-ltsc2022/Dockerfile b/3.14-rc/windows/windowsservercore-ltsc2022/Dockerfile index c32811229..d177ea7b6 100644 --- a/3.14-rc/windows/windowsservercore-ltsc2022/Dockerfile +++ b/3.14-rc/windows/windowsservercore-ltsc2022/Dockerfile @@ -11,8 +11,8 @@ SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPref # https://github.com/docker-library/python/pull/557 ENV PYTHONIOENCODING UTF-8 -ENV PYTHON_VERSION 3.14.0a7 -ENV PYTHON_SHA256 944e24cde04e4067ae728578afc8fbc78d9a0d735e9c9348720c857d61bd8e1e +ENV PYTHON_VERSION 3.14.0b1 +ENV PYTHON_SHA256 a878026c12b1a606d02f5bbf3ed65aa780ee8272964b8f95d8348ffa2d6ca096 RUN $url = ('https://www.python.org/ftp/python/{0}/python-{1}-amd64.exe' -f ($env:PYTHON_VERSION -replace '[a-z]+[0-9]*$', ''), $env:PYTHON_VERSION); \ Write-Host ('Downloading {0} ...' -f $url); \ diff --git a/3.14-rc/windows/windowsservercore-ltsc2025/Dockerfile b/3.14-rc/windows/windowsservercore-ltsc2025/Dockerfile index 8845be9da..5d3b7d088 100644 --- a/3.14-rc/windows/windowsservercore-ltsc2025/Dockerfile +++ b/3.14-rc/windows/windowsservercore-ltsc2025/Dockerfile @@ -11,8 +11,8 @@ SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPref # https://github.com/docker-library/python/pull/557 ENV PYTHONIOENCODING UTF-8 -ENV PYTHON_VERSION 3.14.0a7 -ENV PYTHON_SHA256 944e24cde04e4067ae728578afc8fbc78d9a0d735e9c9348720c857d61bd8e1e +ENV PYTHON_VERSION 3.14.0b1 +ENV PYTHON_SHA256 a878026c12b1a606d02f5bbf3ed65aa780ee8272964b8f95d8348ffa2d6ca096 RUN $url = ('https://www.python.org/ftp/python/{0}/python-{1}-amd64.exe' -f ($env:PYTHON_VERSION -replace '[a-z]+[0-9]*$', ''), $env:PYTHON_VERSION); \ Write-Host ('Downloading {0} ...' -f $url); \ diff --git a/versions.json b/versions.json index ef3e40b11..a6141223d 100644 --- a/versions.json +++ b/versions.json @@ -84,10 +84,10 @@ "3.14-rc": { "checksums": { "source": { - "sha256": "71adbcec3ac9edf93308e55cfb4184f2eb4b16fda2bb0a5a382929ed29c8386d" + "sha256": "2ddd30a77c9f62e065ce648664a254b9b0c011bcdaa8c1c2787087e644cbeb39" }, "windows": { - "sha256": "944e24cde04e4067ae728578afc8fbc78d9a0d735e9c9348720c857d61bd8e1e" + "sha256": "a878026c12b1a606d02f5bbf3ed65aa780ee8272964b8f95d8348ffa2d6ca096" } }, "variants": [ @@ -101,7 +101,7 @@ "windows/windowsservercore-ltsc2022", "windows/windowsservercore-1809" ], - "version": "3.14.0a7" + "version": "3.14.0b1" }, "3.9": { "checksums": { From 0fb50d347fe0df6a92b492ed52d012cb4d502627 Mon Sep 17 00:00:00 2001 From: Joseph Ferguson Date: Thu, 8 May 2025 12:01:55 -0700 Subject: [PATCH 2/3] Add a quick fix for 3.14.0b1 on windows --- 3.14-rc/windows/windowsservercore-1809/Dockerfile | 7 +++++++ 3.14-rc/windows/windowsservercore-ltsc2022/Dockerfile | 7 +++++++ 3.14-rc/windows/windowsservercore-ltsc2025/Dockerfile | 7 +++++++ Dockerfile-windows.template | 9 +++++++++ 4 files changed, 30 insertions(+) diff --git a/3.14-rc/windows/windowsservercore-1809/Dockerfile b/3.14-rc/windows/windowsservercore-1809/Dockerfile index ca6012734..61a8ce521 100644 --- a/3.14-rc/windows/windowsservercore-1809/Dockerfile +++ b/3.14-rc/windows/windowsservercore-1809/Dockerfile @@ -57,6 +57,13 @@ RUN $url = ('https://www.python.org/ftp/python/{0}/python-{1}-amd64.exe' -f ($en \ $env:PYTHONDONTWRITEBYTECODE = '1'; \ \ + Write-Host 'Reinstalling pip to workaround a bug ...'; \ + # https://github.com/python/cpython/issues/133626 + # clean up broken pip install + Remove-Item -Recurse C:\Python\Lib\site-packages\pip*; \ + # install pip as pip.exe + python -m ensurepip --default-pip -vvv; \ + \ Write-Host 'Verifying pip install ...'; \ pip --version; \ \ diff --git a/3.14-rc/windows/windowsservercore-ltsc2022/Dockerfile b/3.14-rc/windows/windowsservercore-ltsc2022/Dockerfile index d177ea7b6..75ffda7b0 100644 --- a/3.14-rc/windows/windowsservercore-ltsc2022/Dockerfile +++ b/3.14-rc/windows/windowsservercore-ltsc2022/Dockerfile @@ -57,6 +57,13 @@ RUN $url = ('https://www.python.org/ftp/python/{0}/python-{1}-amd64.exe' -f ($en \ $env:PYTHONDONTWRITEBYTECODE = '1'; \ \ + Write-Host 'Reinstalling pip to workaround a bug ...'; \ + # https://github.com/python/cpython/issues/133626 + # clean up broken pip install + Remove-Item -Recurse C:\Python\Lib\site-packages\pip*; \ + # install pip as pip.exe + python -m ensurepip --default-pip -vvv; \ + \ Write-Host 'Verifying pip install ...'; \ pip --version; \ \ diff --git a/3.14-rc/windows/windowsservercore-ltsc2025/Dockerfile b/3.14-rc/windows/windowsservercore-ltsc2025/Dockerfile index 5d3b7d088..ffc2b344d 100644 --- a/3.14-rc/windows/windowsservercore-ltsc2025/Dockerfile +++ b/3.14-rc/windows/windowsservercore-ltsc2025/Dockerfile @@ -57,6 +57,13 @@ RUN $url = ('https://www.python.org/ftp/python/{0}/python-{1}-amd64.exe' -f ($en \ $env:PYTHONDONTWRITEBYTECODE = '1'; \ \ + Write-Host 'Reinstalling pip to workaround a bug ...'; \ + # https://github.com/python/cpython/issues/133626 + # clean up broken pip install + Remove-Item -Recurse C:\Python\Lib\site-packages\pip*; \ + # install pip as pip.exe + python -m ensurepip --default-pip -vvv; \ + \ Write-Host 'Verifying pip install ...'; \ pip --version; \ \ diff --git a/Dockerfile-windows.template b/Dockerfile-windows.template index add70eac7..115b08c21 100644 --- a/Dockerfile-windows.template +++ b/Dockerfile-windows.template @@ -55,6 +55,15 @@ RUN $url = ('https://www.python.org/ftp/python/{0}/python-{1}-amd64.exe' -f ($en \ $env:PYTHONDONTWRITEBYTECODE = '1'; \ \ +{{ if .version == "3.14.0b1" then ( -}} + Write-Host 'Reinstalling pip to workaround a bug ...'; \ + # https://github.com/python/cpython/issues/133626 + # clean up broken pip install + Remove-Item -Recurse C:\Python\Lib\site-packages\pip*; \ + # install pip as pip.exe + python -m ensurepip --default-pip -vvv; \ + \ +{{ ) else "" end -}} Write-Host 'Verifying pip install ...'; \ pip --version; \ \ From 90aa427282f3f8283652c97011a511a77ea699b8 Mon Sep 17 00:00:00 2001 From: Michael Moll Date: Mon, 5 May 2025 21:55:26 +0200 Subject: [PATCH 3/3] disable LTO in RISC-V to speed up build --- 3.10/alpine3.20/Dockerfile | 2 +- 3.10/alpine3.21/Dockerfile | 2 +- 3.10/bookworm/Dockerfile | 2 +- 3.10/bullseye/Dockerfile | 2 +- 3.10/slim-bookworm/Dockerfile | 2 +- 3.10/slim-bullseye/Dockerfile | 2 +- 3.11/alpine3.20/Dockerfile | 2 +- 3.11/alpine3.21/Dockerfile | 2 +- 3.11/bookworm/Dockerfile | 2 +- 3.11/bullseye/Dockerfile | 2 +- 3.11/slim-bookworm/Dockerfile | 2 +- 3.11/slim-bullseye/Dockerfile | 2 +- 3.12/alpine3.20/Dockerfile | 2 +- 3.12/alpine3.21/Dockerfile | 2 +- 3.12/bookworm/Dockerfile | 2 +- 3.12/bullseye/Dockerfile | 2 +- 3.12/slim-bookworm/Dockerfile | 2 +- 3.12/slim-bullseye/Dockerfile | 2 +- 3.13/alpine3.20/Dockerfile | 2 +- 3.13/alpine3.21/Dockerfile | 2 +- 3.13/bookworm/Dockerfile | 2 +- 3.13/bullseye/Dockerfile | 2 +- 3.13/slim-bookworm/Dockerfile | 2 +- 3.13/slim-bullseye/Dockerfile | 2 +- 3.14-rc/alpine3.20/Dockerfile | 2 +- 3.14-rc/alpine3.21/Dockerfile | 2 +- 3.14-rc/bookworm/Dockerfile | 2 +- 3.14-rc/bullseye/Dockerfile | 2 +- 3.14-rc/slim-bookworm/Dockerfile | 2 +- 3.14-rc/slim-bullseye/Dockerfile | 2 +- Dockerfile-linux.template | 3 ++- generate-stackbrew-library.sh | 6 ------ 32 files changed, 32 insertions(+), 37 deletions(-) diff --git a/3.10/alpine3.20/Dockerfile b/3.10/alpine3.20/Dockerfile index b46a12d48..0fed3b855 100644 --- a/3.10/alpine3.20/Dockerfile +++ b/3.10/alpine3.20/Dockerfile @@ -76,7 +76,7 @@ RUN set -eux; \ --enable-loadable-sqlite-extensions \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.10/alpine3.21/Dockerfile b/3.10/alpine3.21/Dockerfile index 3c03960a8..bde84e689 100644 --- a/3.10/alpine3.21/Dockerfile +++ b/3.10/alpine3.21/Dockerfile @@ -76,7 +76,7 @@ RUN set -eux; \ --enable-loadable-sqlite-extensions \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.10/bookworm/Dockerfile b/3.10/bookworm/Dockerfile index ddc2cfe13..365c28eb3 100644 --- a/3.10/bookworm/Dockerfile +++ b/3.10/bookworm/Dockerfile @@ -50,7 +50,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.10/bullseye/Dockerfile b/3.10/bullseye/Dockerfile index ef1ad6771..df9e90582 100644 --- a/3.10/bullseye/Dockerfile +++ b/3.10/bullseye/Dockerfile @@ -50,7 +50,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.10/slim-bookworm/Dockerfile b/3.10/slim-bookworm/Dockerfile index 8c3a84d47..28ea16618 100644 --- a/3.10/slim-bookworm/Dockerfile +++ b/3.10/slim-bookworm/Dockerfile @@ -75,7 +75,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.10/slim-bullseye/Dockerfile b/3.10/slim-bullseye/Dockerfile index eee742510..a8758f729 100644 --- a/3.10/slim-bullseye/Dockerfile +++ b/3.10/slim-bullseye/Dockerfile @@ -75,7 +75,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.11/alpine3.20/Dockerfile b/3.11/alpine3.20/Dockerfile index 6bfbfc584..5d5a0be1a 100644 --- a/3.11/alpine3.20/Dockerfile +++ b/3.11/alpine3.20/Dockerfile @@ -76,7 +76,7 @@ RUN set -eux; \ --enable-loadable-sqlite-extensions \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.11/alpine3.21/Dockerfile b/3.11/alpine3.21/Dockerfile index 858ce0232..78e40d489 100644 --- a/3.11/alpine3.21/Dockerfile +++ b/3.11/alpine3.21/Dockerfile @@ -76,7 +76,7 @@ RUN set -eux; \ --enable-loadable-sqlite-extensions \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.11/bookworm/Dockerfile b/3.11/bookworm/Dockerfile index 943aa0150..f6a7a9a40 100644 --- a/3.11/bookworm/Dockerfile +++ b/3.11/bookworm/Dockerfile @@ -50,7 +50,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.11/bullseye/Dockerfile b/3.11/bullseye/Dockerfile index cad17e31e..4b7d3f217 100644 --- a/3.11/bullseye/Dockerfile +++ b/3.11/bullseye/Dockerfile @@ -50,7 +50,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.11/slim-bookworm/Dockerfile b/3.11/slim-bookworm/Dockerfile index 1d77b85f6..3634bae14 100644 --- a/3.11/slim-bookworm/Dockerfile +++ b/3.11/slim-bookworm/Dockerfile @@ -75,7 +75,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.11/slim-bullseye/Dockerfile b/3.11/slim-bullseye/Dockerfile index 250c1c031..e89207c9d 100644 --- a/3.11/slim-bullseye/Dockerfile +++ b/3.11/slim-bullseye/Dockerfile @@ -75,7 +75,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.12/alpine3.20/Dockerfile b/3.12/alpine3.20/Dockerfile index a7c1b0de9..9519e47a9 100644 --- a/3.12/alpine3.20/Dockerfile +++ b/3.12/alpine3.20/Dockerfile @@ -76,7 +76,7 @@ RUN set -eux; \ --enable-loadable-sqlite-extensions \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.12/alpine3.21/Dockerfile b/3.12/alpine3.21/Dockerfile index 38dfd364a..9b2b2fe71 100644 --- a/3.12/alpine3.21/Dockerfile +++ b/3.12/alpine3.21/Dockerfile @@ -76,7 +76,7 @@ RUN set -eux; \ --enable-loadable-sqlite-extensions \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.12/bookworm/Dockerfile b/3.12/bookworm/Dockerfile index c85c9bf80..3c5dadda8 100644 --- a/3.12/bookworm/Dockerfile +++ b/3.12/bookworm/Dockerfile @@ -50,7 +50,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.12/bullseye/Dockerfile b/3.12/bullseye/Dockerfile index af9f71f1a..db27cbbe8 100644 --- a/3.12/bullseye/Dockerfile +++ b/3.12/bullseye/Dockerfile @@ -50,7 +50,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.12/slim-bookworm/Dockerfile b/3.12/slim-bookworm/Dockerfile index 426f71f4d..f476f736a 100644 --- a/3.12/slim-bookworm/Dockerfile +++ b/3.12/slim-bookworm/Dockerfile @@ -75,7 +75,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.12/slim-bullseye/Dockerfile b/3.12/slim-bullseye/Dockerfile index 960607d0f..1e5f18c20 100644 --- a/3.12/slim-bullseye/Dockerfile +++ b/3.12/slim-bullseye/Dockerfile @@ -75,7 +75,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.13/alpine3.20/Dockerfile b/3.13/alpine3.20/Dockerfile index 5b2fe3f23..c3b9eb310 100644 --- a/3.13/alpine3.20/Dockerfile +++ b/3.13/alpine3.20/Dockerfile @@ -71,7 +71,7 @@ RUN set -eux; \ --enable-loadable-sqlite-extensions \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.13/alpine3.21/Dockerfile b/3.13/alpine3.21/Dockerfile index 42837829e..c289fda11 100644 --- a/3.13/alpine3.21/Dockerfile +++ b/3.13/alpine3.21/Dockerfile @@ -71,7 +71,7 @@ RUN set -eux; \ --enable-loadable-sqlite-extensions \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.13/bookworm/Dockerfile b/3.13/bookworm/Dockerfile index 21bfb2371..4a3f8a2b1 100644 --- a/3.13/bookworm/Dockerfile +++ b/3.13/bookworm/Dockerfile @@ -45,7 +45,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.13/bullseye/Dockerfile b/3.13/bullseye/Dockerfile index 17a2df6f7..1267fa3e6 100644 --- a/3.13/bullseye/Dockerfile +++ b/3.13/bullseye/Dockerfile @@ -45,7 +45,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.13/slim-bookworm/Dockerfile b/3.13/slim-bookworm/Dockerfile index 2e20f91d3..15a408ab7 100644 --- a/3.13/slim-bookworm/Dockerfile +++ b/3.13/slim-bookworm/Dockerfile @@ -70,7 +70,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.13/slim-bullseye/Dockerfile b/3.13/slim-bullseye/Dockerfile index 1a1fd9b87..09ba3b8c2 100644 --- a/3.13/slim-bullseye/Dockerfile +++ b/3.13/slim-bullseye/Dockerfile @@ -70,7 +70,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.14-rc/alpine3.20/Dockerfile b/3.14-rc/alpine3.20/Dockerfile index a6bbb3c13..832c5e59b 100644 --- a/3.14-rc/alpine3.20/Dockerfile +++ b/3.14-rc/alpine3.20/Dockerfile @@ -64,7 +64,7 @@ RUN set -eux; \ --enable-loadable-sqlite-extensions \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.14-rc/alpine3.21/Dockerfile b/3.14-rc/alpine3.21/Dockerfile index a84256a6a..39b392e95 100644 --- a/3.14-rc/alpine3.21/Dockerfile +++ b/3.14-rc/alpine3.21/Dockerfile @@ -64,7 +64,7 @@ RUN set -eux; \ --enable-loadable-sqlite-extensions \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.14-rc/bookworm/Dockerfile b/3.14-rc/bookworm/Dockerfile index 3770ba0e7..b6b99382a 100644 --- a/3.14-rc/bookworm/Dockerfile +++ b/3.14-rc/bookworm/Dockerfile @@ -38,7 +38,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.14-rc/bullseye/Dockerfile b/3.14-rc/bullseye/Dockerfile index 28cb40b2d..34d0fc2a7 100644 --- a/3.14-rc/bullseye/Dockerfile +++ b/3.14-rc/bullseye/Dockerfile @@ -38,7 +38,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.14-rc/slim-bookworm/Dockerfile b/3.14-rc/slim-bookworm/Dockerfile index deae80dd1..ff44902a3 100644 --- a/3.14-rc/slim-bookworm/Dockerfile +++ b/3.14-rc/slim-bookworm/Dockerfile @@ -63,7 +63,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/3.14-rc/slim-bullseye/Dockerfile b/3.14-rc/slim-bullseye/Dockerfile index 0803096ab..9cd8ab9de 100644 --- a/3.14-rc/slim-bullseye/Dockerfile +++ b/3.14-rc/slim-bullseye/Dockerfile @@ -63,7 +63,7 @@ RUN set -eux; \ --enable-optimizations \ --enable-option-checking=fatal \ --enable-shared \ - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ --with-ensurepip \ ; \ nproc="$(nproc)"; \ diff --git a/Dockerfile-linux.template b/Dockerfile-linux.template index 7c62579cf..8b3b8c824 100644 --- a/Dockerfile-linux.template +++ b/Dockerfile-linux.template @@ -180,9 +180,10 @@ RUN set -eux; \ --enable-shared \ {{ # <3.10 does not have -fno-semantic-interposition enabled and --with-lto does nothing for performance + # skip LTO on alpine on riscv64: https://github.com/docker-library/python/pull/935, https://github.com/docker-library/python/pull/1038 if rcVersion == "3.9" then "" else ( -}} - --with-lto \ + $(test "$gnuArch" != 'riscv64-linux-musl' && echo '--with-lto') \ {{ ) end -}} --with-ensurepip \ ; \ diff --git a/generate-stackbrew-library.sh b/generate-stackbrew-library.sh index f6f64ca36..a1ef13fe7 100755 --- a/generate-stackbrew-library.sh +++ b/generate-stackbrew-library.sh @@ -136,12 +136,6 @@ for version; do ;; esac - # https://github.com/docker-library/python/pull/931 (riscv64 builds on 3.11+ take way too long 😞) - case "$version" in - 3.9 | 3.10) ;; - *) variantArches="$(sed <<<" $variantArches " -e 's/ riscv64 / /g')" ;; - esac - # https://github.com/python/cpython/issues/93619 (Linking error when building 3.11 beta on mips64le) + https://peps.python.org/pep-0011/ (mips is not even tier 3) case "$version" in 3.9) ;;