diff --git a/bin/update_docker.py b/bin/update_docker.py index 3c6ef79e..20573a7f 100755 --- a/bin/update_docker.py +++ b/bin/update_docker.py @@ -43,7 +43,17 @@ images = [ ), # manylinux_2_28 images PyPAImage( - "manylinux_2_28", ["x86_64", "aarch64", "ppc64le", "s390x", "pypy_x86_64", "pypy_aarch64"] + "manylinux_2_28", + [ + "x86_64", + "i686", + "aarch64", + "ppc64le", + "s390x", + "pypy_x86_64", + "pypy_i686", + "pypy_aarch64", + ], ), # manylinux_2_31 images PyPAImage("manylinux_2_31", ["armv7l"]), diff --git a/cibuildwheel/resources/defaults.toml b/cibuildwheel/resources/defaults.toml index 396c1d3c..6a57f2d0 100644 --- a/cibuildwheel/resources/defaults.toml +++ b/cibuildwheel/resources/defaults.toml @@ -31,14 +31,14 @@ container-engine = "docker" pyodide-version = "" manylinux-x86_64-image = "manylinux_2_28" -manylinux-i686-image = "manylinux2014" +manylinux-i686-image = "manylinux_2_28" manylinux-aarch64-image = "manylinux_2_28" manylinux-ppc64le-image = "manylinux_2_28" manylinux-s390x-image = "manylinux_2_28" manylinux-armv7l-image = "manylinux_2_31" manylinux-riscv64-image = "ghcr.io/pypa/cibuildwheel/no_default_image:please_use_override" manylinux-pypy_x86_64-image = "manylinux_2_28" -manylinux-pypy_i686-image = "manylinux2014" +manylinux-pypy_i686-image = "manylinux_2_28" manylinux-pypy_aarch64-image = "manylinux_2_28" musllinux-x86_64-image = "musllinux_1_2" diff --git a/cibuildwheel/resources/pinned_docker_images.cfg b/cibuildwheel/resources/pinned_docker_images.cfg index 2dd897df..a6b55073 100644 --- a/cibuildwheel/resources/pinned_docker_images.cfg +++ b/cibuildwheel/resources/pinned_docker_images.cfg @@ -6,6 +6,7 @@ musllinux_1_2 = quay.io/pypa/musllinux_1_2_x86_64:2025.06.28-1 [i686] manylinux2014 = quay.io/pypa/manylinux2014_i686:2025.06.28-1 +manylinux_2_28 = quay.io/pypa/manylinux_2_28_i686:2025.06.28-1 musllinux_1_2 = quay.io/pypa/musllinux_1_2_i686:2025.06.28-1 [aarch64] @@ -33,6 +34,7 @@ manylinux_2_34 = quay.io/pypa/manylinux_2_34_x86_64:2025.06.28-1 [pypy_i686] manylinux2014 = quay.io/pypa/manylinux2014_i686:2025.06.28-1 +manylinux_2_28 = quay.io/pypa/manylinux_2_28_i686:2025.06.28-1 [pypy_aarch64] manylinux2014 = quay.io/pypa/manylinux2014_aarch64:2025.06.28-1 diff --git a/docs/options.md b/docs/options.md index 6718c64f..ed2fadcb 100644 --- a/docs/options.md +++ b/docs/options.md @@ -1009,7 +1009,7 @@ The available options are: | Option | Default | |--------------------------------|-----------------------------------------------------------------| | `manylinux_x86_64-image` | [`manylinux_2_28`](https://quay.io/pypa/manylinux_2_28_x86_64) | -| `manylinux-i686-image` | [`manylinux2014`](https://quay.io/pypa/manylinux2014_i686) | +| `manylinux-i686-image` | [`manylinux_2_28`](https://quay.io/pypa/manylinux_2_28_i686) | | `manylinux-pypy_x86_64-image` | [`manylinux_2_28`](https://quay.io/pypa/manylinux_2_28_x86_64) | | `manylinux-aarch64-image` | [`manylinux_2_28`](https://quay.io/pypa/manylinux_2_28_aarch64) | | `manylinux-ppc64le-image` | [`manylinux_2_28`](https://quay.io/pypa/manylinux_2_28_ppc64le) | @@ -1017,7 +1017,7 @@ The available options are: | `manylinux-armv7l-image` | [`manylinux_2_31`](https://quay.io/pypa/manylinux_2_31_armv7l) | | `manylinux-riscv64-image` | No default | | `manylinux-pypy_aarch64-image` | [`manylinux_2_28`](https://quay.io/pypa/manylinux_2_28_aarch64) | -| `manylinux-pypy_i686-image` | [`manylinux2014`](https://quay.io/pypa/manylinux2014_i686) | +| `manylinux-pypy_i686-image` | [`manylinux_2_28`](https://quay.io/pypa/manylinux_2_28_i686) | | `musllinux_x86_64-image` | [`musllinux_1_2`](https://quay.io/pypa/musllinux_1_2_x86_64) | | `musllinux-i686-image` | [`musllinux_1_2`](https://quay.io/pypa/musllinux_1_2_i686) | | `musllinux-aarch64-image` | [`musllinux_1_2`](https://quay.io/pypa/musllinux_1_2_aarch64) | @@ -1029,7 +1029,7 @@ The available options are: Set the Docker image to be used for building [manylinux / musllinux](https://github.com/pypa/manylinux) wheels. For `manylinux-*-image`, except `manylinux-armv7l-image`, the value of this option can either be set to `manylinux2014`, `manylinux_2_28` or `manylinux_2_34` to use a pinned version of the [official manylinux images](https://github.com/pypa/manylinux). Alternatively, set these options to any other valid Docker image name. -`manylinux_2_28` and `manylinux_2_34` are not supported for `i686` architecture. +`manylinux_2_34` is not supported for `i686` architecture. For `manylinux-armv7l-image`, the value of this option can either be set to `manylinux_2_31` or a custom image. Support is experimental for now. The `manylinux_2_31` value is only available for `armv7`. diff --git a/test/test_manylinuxXXXX_only.py b/test/test_manylinuxXXXX_only.py index 483d40f9..8754b363 100644 --- a/test/test_manylinuxXXXX_only.py +++ b/test/test_manylinuxXXXX_only.py @@ -64,7 +64,7 @@ project_with_manylinux_symbols = test_projects.new_c_project( def test(manylinux_image, tmp_path): if utils.get_platform() != "linux": pytest.skip("the container image test is only relevant to the linux build") - elif manylinux_image in {"manylinux_2_28", "manylinux_2_34"} and platform.machine() == "i686": + elif manylinux_image == "manylinux_2_34" and platform.machine() == "i686": pytest.skip(f"{manylinux_image} doesn't exist for i686 architecture") project_dir = tmp_path / "project" @@ -85,8 +85,8 @@ def test(manylinux_image, tmp_path): "CIBW_MANYLINUX_PYPY_AARCH64_IMAGE": manylinux_image, "CIBW_MANYLINUX_PYPY_I686_IMAGE": manylinux_image, } - if manylinux_image in {"manylinux_2_28", "manylinux_2_34"} and platform.machine() == "x86_64": - # We don't have a manylinux_2_28+ image for i686 + if manylinux_image == "manylinux_2_34" and platform.machine() == "x86_64": + # We don't have a manylinux_2_34+ image for i686 add_env["CIBW_ARCHS"] = "x86_64" if platform.machine() == "aarch64": # We just have a manylinux_2_31 image for armv7l @@ -104,8 +104,8 @@ def test(manylinux_image, tmp_path): musllinux_versions=[], ) - if manylinux_image in {"manylinux_2_28", "manylinux_2_34"} and platform.machine() == "x86_64": - # We don't have a manylinux_2_28+ image for i686 + if manylinux_image == "manylinux_2_34" and platform.machine() == "x86_64": + # We don't have a manylinux_2_34+ image for i686 expected_wheels = [w for w in expected_wheels if "i686" not in w] if platform.machine() == "aarch64": diff --git a/test/utils.py b/test/utils.py index 782934bd..749e54dc 100644 --- a/test/utils.py +++ b/test/utils.py @@ -252,7 +252,7 @@ def _expected_wheels( if manylinux_versions is None: manylinux_versions = { "armv7l": ["manylinux2014", "manylinux_2_17", "manylinux_2_31"], - "i686": ["manylinux1", "manylinux2014", "manylinux_2_17", "manylinux_2_5"], + "i686": ["manylinux1", "manylinux_2_28", "manylinux_2_5"], "x86_64": ["manylinux1", "manylinux_2_28", "manylinux_2_5"], "riscv64": ["manylinux_2_31", "manylinux_2_35"], }.get(machine_arch, ["manylinux2014", "manylinux_2_17", "manylinux_2_28"]) diff --git a/unit_test/main_tests/main_options_test.py b/unit_test/main_tests/main_options_test.py index 731d10ad..cf421ce4 100644 --- a/unit_test/main_tests/main_options_test.py +++ b/unit_test/main_tests/main_options_test.py @@ -111,8 +111,9 @@ def test_empty_selector(monkeypatch): ("x86_64", "manylinux_2_28", "quay.io/pypa/manylinux_2_28_x86_64:*"), ("x86_64", "manylinux_2_34", "quay.io/pypa/manylinux_2_34_x86_64:*"), ("x86_64", "custom_image", "custom_image"), - ("i686", None, "quay.io/pypa/manylinux2014_i686:*"), + ("i686", None, "quay.io/pypa/manylinux_2_28_i686:*"), ("i686", "manylinux2014", "quay.io/pypa/manylinux2014_i686:*"), + ("i686", "manylinux_2_28", "quay.io/pypa/manylinux_2_28_i686:*"), ("i686", "custom_image", "custom_image"), ("pypy_x86_64", None, "quay.io/pypa/manylinux_2_28_x86_64:*"), ("pypy_x86_64", "manylinux2014", "quay.io/pypa/manylinux2014_x86_64:*"), diff --git a/unit_test/option_prepare_test.py b/unit_test/option_prepare_test.py index d2a1a082..945cb3b0 100644 --- a/unit_test/option_prepare_test.py +++ b/unit_test/option_prepare_test.py @@ -70,7 +70,7 @@ def test_build_default_launches(monkeypatch): assert identifiers == {f"{x}-manylinux_x86_64" for x in DEFAULT_IDS} kwargs = build_in_container.call_args_list[1][1] - assert "quay.io/pypa/manylinux2014_i686" in kwargs["container"]["image"] + assert "quay.io/pypa/manylinux_2_28_i686" in kwargs["container"]["image"] assert kwargs["container"]["cwd"] == PurePosixPath("/project") assert kwargs["container"]["oci_platform"] == OCIPlatform.i386 @@ -128,7 +128,7 @@ before-all = "true" build_in_container = typing.cast(mock.Mock, platforms.linux.build_in_container) - assert build_in_container.call_count == 6 + assert build_in_container.call_count == 7 kwargs = build_in_container.call_args_list[0][1] assert "quay.io/pypa/manylinux2014_x86_64" in kwargs["container"]["image"] @@ -189,11 +189,19 @@ before-all = "true" assert "quay.io/pypa/manylinux2014_i686" in kwargs["container"]["image"] assert kwargs["container"]["cwd"] == PurePosixPath("/project") assert kwargs["container"]["oci_platform"] == OCIPlatform.i386 - identifiers = {x.identifier for x in kwargs["platform_configs"]} - assert identifiers == {f"{x}-manylinux_i686" for x in ALL_IDS if "gp" not in x} + assert identifiers == {"cp38-manylinux_i686", "cp39-manylinux_i686"} kwargs = build_in_container.call_args_list[4][1] + assert "quay.io/pypa/manylinux_2_28_i686" in kwargs["container"]["image"] + assert kwargs["container"]["cwd"] == PurePosixPath("/project") + assert kwargs["container"]["oci_platform"] == OCIPlatform.i386 + identifiers = {x.identifier for x in kwargs["platform_configs"]} + assert identifiers == { + f"{x}-manylinux_i686" for x in ALL_IDS - {"cp38", "cp39"} if "gp" not in x + } + + kwargs = build_in_container.call_args_list[5][1] assert "quay.io/pypa/musllinux_1_2_x86_64" in kwargs["container"]["image"] assert kwargs["container"]["cwd"] == PurePosixPath("/project") assert kwargs["container"]["oci_platform"] == OCIPlatform.AMD64 @@ -202,7 +210,7 @@ before-all = "true" f"{x}-musllinux_x86_64" for x in ALL_IDS if "pp" not in x and "gp" not in x } - kwargs = build_in_container.call_args_list[5][1] + kwargs = build_in_container.call_args_list[6][1] assert "quay.io/pypa/musllinux_1_2_i686" in kwargs["container"]["image"] assert kwargs["container"]["cwd"] == PurePosixPath("/project") assert kwargs["container"]["oci_platform"] == OCIPlatform.i386 diff --git a/unit_test/options_toml_test.py b/unit_test/options_toml_test.py index 6ec63415..f256fff6 100644 --- a/unit_test/options_toml_test.py +++ b/unit_test/options_toml_test.py @@ -69,7 +69,7 @@ def test_simple_settings(tmp_path, platform, fname): assert options_reader.get("test-groups", option_format=ListFormat(" ")) == "three four" assert options_reader.get("manylinux-x86_64-image") == "manylinux_2_28" - assert options_reader.get("manylinux-i686-image") == "manylinux2014" + assert options_reader.get("manylinux-i686-image") == "manylinux_2_28" with pytest.raises(OptionsReaderError): # fails because the option is a table and the option_format only works with lists @@ -104,7 +104,7 @@ def test_envvar_override(tmp_path, platform): assert options_reader.get("build") == "cp38*" assert options_reader.get("manylinux-x86_64-image") == "manylinux_2_24" - assert options_reader.get("manylinux-i686-image") == "manylinux2014" + assert options_reader.get("manylinux-i686-image") == "manylinux_2_28" assert ( options_reader.get("xbuild-tools", option_format=ListFormat(" ", quote=shlex.quote))