This release is a pre-release and may not be stable for production use.
wheelmonger
Vendor shared libraries into Python wheels using a custom TOML policy,
producing linux_<arch> platform wheels.
wheelmonger wraps auditwheel and gives you explicit control over which shared libraries are vendored into the wheel, which are assumed to be system-provided, and which are cross-wheel dependencies that should be left untouched.
Installation
pip install wheelmonger
Requires Python 3.12+ and a glibc-based Linux system.
Quick start
1. Write a policy file
Create a policy.toml that classifies your wheel's shared library
dependencies into three lists:
[policy]
vendor = [
"libzmq.so.*",
"libqhull_r.so.*",
]
skip = [
"libtorch.so",
"libtorch_cpu.so",
]
system = [
"libcrypto.so.*",
"libssl.so.*",
"libcurl.so.*",
]
- vendor -- libraries to copy into the wheel and rewrite ELF references.
- skip -- cross-wheel dependencies to leave untouched (e.g. PyTorch).
- system -- libraries assumed present on the target system.
Patterns use fnmatch-style globbing. Libraries on the manylinux allow list
(e.g. libc.so.6, libm.so.6) are always treated as system-provided
automatically.
2. Inspect dependencies
wheelmonger show my_package-1.0-cp314-cp314-linux_x86_64.whl -p policy.toml
3. Repair the wheel
wheelmonger repair my_package-1.0-cp314-cp314-linux_x86_64.whl -p policy.toml
The repaired wheel is written to wheelhouse/ by default. A
CycloneDX SBOM (wheelmonger.cdx.json) is
generated automatically for vendored libraries and stored in the
wheel's .dist-info/sboms/ directory.
Usage
wheelmonger repair WHEEL -p POLICY [-w WHEEL_DIR] [-L LIB_SDIR] [--strip] [-v]
wheelmonger show WHEEL -p POLICY [-v]
repair
| Option | Description |
|---|---|
-p, --policy |
Path to the TOML policy file (or $WHEELMONGER_POLICY) |
-w, --wheel-dir |
Output directory (default: wheelhouse/) |
-L, --lib-sdir |
Subdirectory for vendored libs (default: .libs) |
--strip |
Strip symbols from vendored libraries |
--add-vendor PATTERN |
Additional library pattern to vendor (repeatable; or $WHEELMONGER_VENDOR_LIBS) |
-z, --zip-compression-level |
Zip compression level (default: zlib default) |
-v, --verbose |
Increase verbosity (repeatable) |
show
Displays all shared library dependencies grouped by classification (vendor, manylinux, system, skip, unknown) without modifying the wheel.
Environment variables
| Variable | Description |
|---|---|
WHEELMONGER_POLICY |
Default path to the TOML policy file. Overridden by -p/--policy. |
WHEELMONGER_VENDOR_LIBS |
Additional vendor patterns separated by os.pathsep. |
License
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file wheelmonger-0.1.0a1.tar.gz.
File metadata
- Download URL: wheelmonger-0.1.0a1.tar.gz
- Upload date:
- Size: 40.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4810b242651194ce19ec953a311f90388249734968f84bf0ae6106db23ae70f9
|
|
| MD5 |
63304f9b30d72321629e521765f298a7
|
|
| BLAKE2b-256 |
9ff16c4e87aa36f5e8a172877c4c46240ebfa29f7b331ee5d80033ee8a71b2ee
|
Provenance
The following attestation bundles were made for wheelmonger-0.1.0a1.tar.gz:
Publisher:
release.yml on tiran/wheelmonger
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
wheelmonger-0.1.0a1.tar.gz -
Subject digest:
4810b242651194ce19ec953a311f90388249734968f84bf0ae6106db23ae70f9 - Sigstore transparency entry: 2369265339
- Sigstore integration time:
-
Permalink:
tiran/wheelmonger@908fdd2718ec775e8ee41ab3eae616ff1e014b9b -
Branch / Tag:
refs/tags/v0.1.0a1 - Owner: https://github.com/tiran
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@908fdd2718ec775e8ee41ab3eae616ff1e014b9b -
Trigger Event:
push
-
Statement type:
File details
Details for the file wheelmonger-0.1.0a1-py3-none-any.whl.
File metadata
- Download URL: wheelmonger-0.1.0a1-py3-none-any.whl
- Upload date:
- Size: 13.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a5611e9bd434ff1633ce8a04859c5acf84b994323531f97da9b4252470a0e454
|
|
| MD5 |
6cd100b6d96c6061cfa8124e522b53f4
|
|
| BLAKE2b-256 |
c577463507a5cd1f919d5e505238edf619059a041ddb15d61d9df9b2adbb56d1
|
Provenance
The following attestation bundles were made for wheelmonger-0.1.0a1-py3-none-any.whl:
Publisher:
release.yml on tiran/wheelmonger
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
wheelmonger-0.1.0a1-py3-none-any.whl -
Subject digest:
a5611e9bd434ff1633ce8a04859c5acf84b994323531f97da9b4252470a0e454 - Sigstore transparency entry: 2369265436
- Sigstore integration time:
-
Permalink:
tiran/wheelmonger@908fdd2718ec775e8ee41ab3eae616ff1e014b9b -
Branch / Tag:
refs/tags/v0.1.0a1 - Owner: https://github.com/tiran
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@908fdd2718ec775e8ee41ab3eae616ff1e014b9b -
Trigger Event:
push
-
Statement type: