diff --git a/cpython-unix/base.Dockerfile b/cpython-unix/base.Dockerfile index 580165504..7e666e045 100644 --- a/cpython-unix/base.Dockerfile +++ b/cpython-unix/base.Dockerfile @@ -29,10 +29,6 @@ RUN for s in debian_jessie debian_jessie-updates debian-security_jessie/updates; echo 'Acquire::Retries "5";'; \ ) > /etc/apt/apt.conf.d/99cpython-portable -RUN ( echo 'amd64'; \ - echo 'i386'; \ - ) > /var/lib/dpkg/arch - # apt iterates all available file descriptors up to rlim_max and calls # fcntl(fd, F_SETFD, FD_CLOEXEC). This can result in millions of system calls # (we've seen 1B in the wild) and cause operations to take seconds to minutes. diff --git a/cpython-unix/build-cpython.sh b/cpython-unix/build-cpython.sh index 73fb8c451..fcf469ec1 100755 --- a/cpython-unix/build-cpython.sh +++ b/cpython-unix/build-cpython.sh @@ -91,6 +91,9 @@ fi # Configure nerfs RUNSHARED when cross-compiling, which prevents PGO from running when # we can in fact run the target binaries (e.g. x86_64 host and i686 target). Undo that. +# TODO this may not be needed after removing support for i686 builds. But it +# may still be useful since CPython's definition of cross-compiling has historically +# been very liberal and kicks in when it arguably shouldn't. if [ -n "${CROSS_COMPILING}" ]; then if [ -n "${PYTHON_MEETS_MINIMUM_VERSION_3_14}" ]; then patch -p1 -i ${ROOT}/patch-dont-clear-runshared-14.patch @@ -1058,9 +1061,6 @@ armv7-unknown-linux-gnueabi) armv7-unknown-linux-gnueabihf) PYTHON_ARCH="arm-linux-gnueabihf" ;; -i686-unknown-linux-gnu) - PYTHON_ARCH="i386-linux-gnu" - ;; mips-unknown-linux-gnu) PYTHON_ARCH="mips-linux-gnu" ;; diff --git a/cpython-unix/build-libX11.sh b/cpython-unix/build-libX11.sh index e8f65ad45..bb45028bb 100755 --- a/cpython-unix/build-libX11.sh +++ b/cpython-unix/build-libX11.sh @@ -54,9 +54,6 @@ if [ -n "${CROSS_COMPILING}" ]; then armv7-unknown-linux-gnueabihf) EXTRA_FLAGS="${EXTRA_FLAGS} --enable-malloc0returnsnull" ;; - i686-unknown-linux-gnu) - EXTRA_FLAGS="${EXTRA_FLAGS} --enable-malloc0returnsnull" - ;; mips-unknown-linux-gnu) EXTRA_FLAGS="${EXTRA_FLAGS} --enable-malloc0returnsnull" ;; @@ -81,9 +78,6 @@ if [ -n "${CROSS_COMPILING}" ]; then aarch64-unknown-linux-musl) EXTRA_FLAGS="${EXTRA_FLAGS} --enable-malloc0returnsnull" ;; - i686-unknown-linux-musl) - EXTRA_FLAGS="${EXTRA_FLAGS} --enable-malloc0returnsnull" - ;; mips-unknown-linux-musl) EXTRA_FLAGS="${EXTRA_FLAGS} --enable-malloc0returnsnull" ;; diff --git a/cpython-unix/build.Dockerfile b/cpython-unix/build.Dockerfile index 09e37faba..e44d0a2e2 100644 --- a/cpython-unix/build.Dockerfile +++ b/cpython-unix/build.Dockerfile @@ -1,8 +1,5 @@ {% include 'base.Dockerfile' %} -# libc6-dev:i386 pulls in 32-bit system libraries to enable cross-compiling -# to i386. -# # libffi-dev and zlib1g-dev are present so host Python (during cross-builds) # can build the ctypes and zlib extensions. So comment in build-cpython.sh # for more context. @@ -14,7 +11,6 @@ RUN ulimit -n 10000 && apt-get install \ bzip2 \ file \ libc6-dev \ - libc6-dev:i386 \ libffi-dev \ make \ patch \ diff --git a/cpython-unix/extension-modules.yml b/cpython-unix/extension-modules.yml index c52078573..028eadde5 100644 --- a/cpython-unix/extension-modules.yml +++ b/cpython-unix/extension-modules.yml @@ -249,7 +249,6 @@ _decimal: - define: CONFIG_32=1 targets: - armv7-.* - - i686-.* - mips-.* - mipsel-.* - define: CONFIG_64=1 @@ -299,7 +298,6 @@ _hashlib: # a static library so there isn't a runtime dependency. - name: ':libatomic.a' targets: - - i686-unknown-linux-gnu - mips-unknown-linux-gnu - mipsel-unknown-linux-gnu - x86_64.*-unknown-linux-gnu @@ -570,7 +568,6 @@ _ssl: # a static library so there isn't a runtime dependency. - name: ':libatomic.a' targets: - - i686-unknown-linux-gnu - mips-unknown-linux-gnu - mipsel-unknown-linux-gnu - x86_64.*-unknown-linux-gnu diff --git a/cpython-unix/targets.yml b/cpython-unix/targets.yml index 46a92e31e..1b47dba4b 100644 --- a/cpython-unix/targets.yml +++ b/cpython-unix/targets.yml @@ -318,52 +318,6 @@ armv7-unknown-linux-gnueabihf: - zlib openssl_target: linux-armv4 -i686-unknown-linux-gnu: - host_platforms: - - linux_x86_64 - pythons_supported: - - '3.9' - - '3.10' - - '3.11' - - '3.12' - - '3.13' - - '3.14' - needs_toolchain: true - host_cc: clang - host_cxx: clang++ - target_cc: clang - target_cxx: clang++ - target_cflags: - - '-m32' - - '-fvisibility=hidden' - target_ldflags: - - '-m32' - needs: - - autoconf - - bdb - - binutils - - bzip2 - - expat - - libedit - - libffi - - libX11 - - libXau - - libxcb - - m4 - - mpdecimal - - ncurses - - openssl-3.0 - - patchelf - - sqlite - - tcl - - tk - - tix - - uuid - - xorgproto - - xz - - zlib - openssl_target: linux-x86-clang - mips-unknown-linux-gnu: host_platforms: - linux_x86_64