docs: add delvewheel to diagram, schema defaults, and docs (#2877)
Since delvewheel is now the default repair-wheel-command on Windows, update all places where auditwheel/delocate were referenced but delvewheel was missing: - diagram.html: add delvewheel repair block for Windows (was grouped with ios/pyodide as optional dot) - generate_schema.py: add Windows delvewheel default to the platform loop so schema.json includes the default - schema.json: regenerated with Windows delvewheel default - options.md: add Windows to defaults list, remove outdated tip about delvewheel being early-stage/optional, update examples - contributing.md: add delvewheel to the tool list Assisted-by: OpenCode:glm-5.1 Signed-off-by: Henry Schreiner <henryfs@princeton.edu>
This commit is contained in:
@@ -382,6 +382,7 @@ oses = {
|
||||
|
||||
for os_name, command in [
|
||||
("linux", "auditwheel repair -w {dest_dir} {wheel}"),
|
||||
("windows", "delvewheel repair -w {dest_dir} -v {wheel}"),
|
||||
("macos", "delocate-wheel --require-archs {delocate_archs} -w {dest_dir} -v {wheel}"),
|
||||
("android", "auditwheel repair --ldpaths {ldpaths} -w {dest_dir} {wheel}"),
|
||||
]:
|
||||
|
||||
@@ -1057,7 +1057,20 @@
|
||||
"$ref": "#/properties/pyodide-version"
|
||||
},
|
||||
"repair-wheel-command": {
|
||||
"$ref": "#/properties/repair-wheel-command"
|
||||
"description": "Execute a shell command to repair each built wheel.",
|
||||
"oneOf": [
|
||||
{
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
],
|
||||
"title": "CIBW_REPAIR_WHEEL_COMMAND",
|
||||
"default": "delvewheel repair -w {dest_dir} -v {wheel}"
|
||||
},
|
||||
"test-command": {
|
||||
"$ref": "#/properties/test-command"
|
||||
|
||||
@@ -27,7 +27,7 @@ Other notes:
|
||||
|
||||
### cibuildwheel's relationship with build errors
|
||||
|
||||
cibuildwheel doesn't really do anything itself - it's always deferring to other tools (pip, wheel, auditwheel, delocate, docker). Without cibuildwheel, the process is really fragmented. Different tools, across different OSs need to be stitched together in just the right way to make it work.
|
||||
cibuildwheel doesn't really do anything itself - it's always deferring to other tools (pip, wheel, auditwheel, delocate, delvewheel, docker). Without cibuildwheel, the process is really fragmented. Different tools, across different OSs need to be stitched together in just the right way to make it work.
|
||||
|
||||
We're not responsible for errors in those tools, for fixing errors/crashes there. But cibuildwheel's job is providing users with an 'integrated' user experience across those tools. We provide an abstraction. The user says 'build me some wheels', not 'open the docker container, build a wheel with pip, fix up the symbols with auditwheel' etc. However, errors have a habit of breaking abstractions. And this is where users get confused, because the mechanism of cibuildwheel is laid bare, and they must understand a little bit how it works to debug.
|
||||
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 96 KiB After Width: | Height: | Size: 101 KiB |
+12
-1
@@ -190,8 +190,19 @@
|
||||
},
|
||||
},
|
||||
{
|
||||
label: 'Repair using delvewheel',
|
||||
href: 'options/#repair-wheel-command',
|
||||
platforms: ['windows', 'ios', 'pyodide'],
|
||||
platforms: ['windows'],
|
||||
style: 'block',
|
||||
tooltip: {
|
||||
title: 'CIBW_REPAIR_WHEEL_COMMAND',
|
||||
tag: 'Customisable step',
|
||||
description: 'Bundle shared libraries by running delvewheel on each built wheel.'
|
||||
},
|
||||
},
|
||||
{
|
||||
href: 'options/#repair-wheel-command',
|
||||
platforms: ['ios', 'pyodide'],
|
||||
style: 'dot',
|
||||
tooltip: {
|
||||
title: 'CIBW_REPAIR_WHEEL_COMMAND',
|
||||
|
||||
+5
-15
@@ -959,6 +959,7 @@ Platform-specific environment variables are also available:<br/>
|
||||
Default:
|
||||
|
||||
- on Linux: `'auditwheel repair -w {dest_dir} {wheel}'`
|
||||
- on Windows: `'delvewheel repair -w {dest_dir} -v {wheel}'`
|
||||
- on macOS: `'delocate-wheel --require-archs {delocate_archs} -w {dest_dir} -v {wheel}'`
|
||||
- on Android: `'auditwheel repair --ldpaths {ldpaths} -w {dest_dir} {wheel}'`
|
||||
- on Pyodide: You can use `pyodide auditwheel repair --libdir /path/to/libraries --output-dir {dest_dir} {wheel}` command to repair the wheel.
|
||||
@@ -984,24 +985,14 @@ The command is run in a shell, so you can run multiple commands like `cmd1 && cm
|
||||
Platform-specific environment variables are also available:<br/>
|
||||
`CIBW_REPAIR_WHEEL_COMMAND_MACOS` | `CIBW_REPAIR_WHEEL_COMMAND_WINDOWS` | `CIBW_REPAIR_WHEEL_COMMAND_LINUX` | `CIBW_REPAIR_WHEEL_COMMAND_ANDROID` | `CIBW_REPAIR_WHEEL_COMMAND_IOS` | `CIBW_REPAIR_WHEEL_COMMAND_PYODIDE`
|
||||
|
||||
!!! tip
|
||||
cibuildwheel doesn't yet ship a default repair command for Windows.
|
||||
|
||||
**If that's an issue for you, check out [delvewheel]** - a new package that aims to do the same as auditwheel or delocate for Windows.
|
||||
|
||||
Because delvewheel is still relatively early-stage, cibuildwheel does not yet run it by default. However, we'd recommend giving it a try! See the examples below for usage.
|
||||
|
||||
[Delvewheel]: https://github.com/adang1345/delvewheel
|
||||
|
||||
#### Examples
|
||||
|
||||
!!! tab examples "pyproject.toml"
|
||||
|
||||
```toml
|
||||
# Use delvewheel on windows
|
||||
# Don't repair Windows wheels
|
||||
[tool.cibuildwheel.windows]
|
||||
before-build = "pip install delvewheel"
|
||||
repair-wheel-command = "delvewheel repair -w {dest_dir} {wheel}"
|
||||
repair-wheel-command = ""
|
||||
|
||||
# Don't repair macOS wheels
|
||||
[tool.cibuildwheel.macos]
|
||||
@@ -1029,9 +1020,8 @@ Platform-specific environment variables are also available:<br/>
|
||||
!!! tab examples "Environment variables"
|
||||
|
||||
```yaml
|
||||
# Use delvewheel on windows
|
||||
CIBW_BEFORE_BUILD_WINDOWS: "pip install delvewheel"
|
||||
CIBW_REPAIR_WHEEL_COMMAND_WINDOWS: "delvewheel repair -w {dest_dir} {wheel}"
|
||||
# Don't repair Windows wheels
|
||||
CIBW_REPAIR_WHEEL_COMMAND_WINDOWS: ""
|
||||
|
||||
# Don't repair macOS wheels
|
||||
CIBW_REPAIR_WHEEL_COMMAND_MACOS: ""
|
||||
|
||||
Reference in New Issue
Block a user