docs: update for uv backend (#2736)

This commit is contained in:
Henry Schreiner
2026-02-08 08:35:24 -05:00
committed by GitHub
parent e0af304d30
commit 9d4c80f487
3 changed files with 22 additions and 9 deletions
@@ -107,13 +107,14 @@
},
"build-frontend": {
"default": "default",
"description": "Set the tool to use to build, either \"build\" (default), \"build[uv]\", or \"pip\"",
"description": "Set the tool to use to build, either \"build\" (default), \"build[uv]\", \"uv\", or \"pip\"",
"oneOf": [
{
"enum": [
"pip",
"build",
"build[uv]",
"uv",
"default"
]
},
@@ -129,6 +130,10 @@
"type": "string",
"pattern": "^build\\[uv\\]; ?args:"
},
{
"type": "string",
"pattern": "^uv; ?args:"
},
{
"type": "object",
"additionalProperties": false,
@@ -140,7 +145,8 @@
"enum": [
"pip",
"build",
"build[uv]"
"build[uv]",
"uv"
]
},
"args": {
+9
View File
@@ -465,6 +465,7 @@ Options:
- `build[;args: ...]`
- `build[uv][;args: ...]`
- `pip[;args: ...]`
- `uv[;args: ...]`
Default: `build`
@@ -478,6 +479,8 @@ pre-installing it, or installing cibuildwheel with the `uv` extra, which is
possible by manually passing `cibuildwheel[uv]` to installers or by using the
`extras` option in the [cibuildwheel action](ci-services.md#github-actions).
uv currently does not support iOS or musllinux on s390x, ppc64le and riscv64.
You can also use the `uv` backend directly; though currently multiple output
files (from workspaces) are not supported.
On Android and Pyodide, the "pip" frontend is not supported.
@@ -511,6 +514,9 @@ optional `args` option.
# Use uv and build with an argument
build-frontend = { name = "build[uv]", args = ["--no-isolation"] }
# Use uv directly
build-frontend = "uv"
```
!!! tab examples "Environment variables"
@@ -527,6 +533,9 @@ optional `args` option.
# Use uv and build with an argument
CIBW_BUILD_FRONTEND: "build[uv]; args: --no-isolation"
# Use uv directly
CIBW_BUILD_FRONTEND: "uv"
```
+5 -7
View File
@@ -185,7 +185,7 @@ Currently, it's recommended to run tests using a `python -m` entrypoint, rather
### Prerequisites
cibuildwheel can build Android wheels on any POSIX platform supported by the Android
development tools, which currently means Linux x86_64, macOS ARM64 or macOS x86_64. Any
development tools, which currently means Linux `x86_64`, macOS `ARM64` or macOS `x86_64`. Any
of these platforms can be used to build wheels for any Android architecture supported by
Python. However, *testing* wheels has additional requirements: see the section below.
@@ -221,10 +221,8 @@ Python 3.13.
### Build frontend support
Android builds only support the `build` frontend. In principle, support for the
`build[uv]` frontend should be possible, but `uv` [doesn't currently have support for
cross-platform builds](https://github.com/astral-sh/uv/issues/7957), and [doesn't have
support for iOS or Android wheel tags](https://github.com/astral-sh/uv/issues/8029).
Android builds do not support the `pip` frontend. The `build`, `build[uv]`, and
`uv` frontends work.
### Tests
@@ -238,7 +236,7 @@ Any arguments specified using [`test-runtime`](options.md#test-runtime) will be
Running an emulator requires the build machine to either be bare-metal or support
nested virtualization. CI platforms known to meet this requirement are:
* GitHub Actions Linux x86_64
* GitHub Actions Linux `x86_64`
On Linux, the emulator needs access to the KVM virtualization interface. This may
require adding your user to a group, or changing your udev rules. On GitHub
@@ -308,7 +306,7 @@ iOS builds are *cross platform builds*, as it not possible to run compilers and
### Build frontend support
iOS builds support both the `pip` and `build` build frontends. In principle, support for `uv` with the `build[uv]` frontend should be possible, but `uv` [doesn't currently have support for cross-platform builds](https://github.com/astral-sh/uv/issues/7957), and [doesn't have support for iOS (or Android) tags](https://github.com/astral-sh/uv/issues/8029).
iOS builds support both the `pip` and `build` build frontends. In principle, support for `uv` and `build[uv]` frontends should be possible, but `uv` [doesn't support iOS fully yet](https://github.com/astral-sh/uv/issues/16724).
### Build environment