Build the crate into python packages Usage: maturin[EXE] build [OPTIONS] [ARGS]... Arguments: [ARGS]... Rustc flags Options: --strip Strip the library for minimum file size --sdist Build a source distribution --compatibility [...] Control the platform tag and PyPI compatibility. This options offers both fine-grained control over the linux libc tag and a more automatic PyPI-compatibility option. The `pypi` option applies on all platforms and ensure that only tags that can be uploaded to PyPI are used. The linux-specific options are `manylinux` tags (for example `manylinux2014`/`manylinux_2_24`) or `musllinux` tags (for example `musllinux_1_2`), and `linux` for the native linux tag. They are ignored on non-linux platforms. Note that `manylinux1` and `manylinux2010` are unsupported by the rust compiler. Wheels with the native `linux` tag will be rejected by pypi, unless they are separately validated by `auditwheel`. The default is the lowest compatible `manylinux` tag, or plain `linux` if nothing matched. -i, --interpreter [...] The python versions to build wheels for, given as the executables of interpreters such as `python3.9` or `/usr/bin/python3.8` -f, --find-interpreter Find interpreters from the host machine -b, --bindings Which kind of bindings to use [possible values: pyo3, pyo3-ffi, cffi, uniffi, bin] -o, --out The directory to store the built wheels in. Defaults to a new "wheels" directory in the project's target directory --auditwheel Audit wheel for manylinux compliance Possible values: - repair: Audit and repair wheel for manylinux compliance - check: Check wheel for manylinux compliance, but do not repair - skip: Don't check for manylinux compliance --zig For manylinux targets, use zig to ensure compliance for the chosen manylinux version Default to manylinux2014/manylinux_2_17 if you do not specify an `--compatibility` Make sure you installed zig with `pip install maturin[zig]` -q, --quiet Do not print cargo log messages --ignore-rust-version Ignore `rust-version` specification in packages -v, --verbose... Use verbose output (-vv very verbose/build.rs output) --color Coloring: auto, always, never --config Override a configuration value (unstable) -Z Unstable (nightly-only) flags to Cargo, see 'cargo -Z help' for details --future-incompat-report Outputs a future incompatibility report at the end of the build (unstable) --compression-method Zip compression method. Only Stored and Deflated are currently compatible with all package managers [default: deflated] Possible values: - deflated: Deflate compression (levels 0-9, default 6) - stored: No compression - bzip2: BZIP2 compression (levels 0-9, default 6) - zstd: Zstandard compression (supported from Python 3.14; levels -7-22, default 3) --compression-level Zip compression level. Defaults to method default -h, --help Print help (see a summary with '-h') Compilation Options: -r, --release Build artifacts in release mode, with optimizations -j, --jobs Number of parallel jobs, defaults to # of CPUs --profile Build artifacts with the specified Cargo profile --target Build for the target triple [env: CARGO_BUILD_TARGET=] --target-dir Directory for all generated artifacts --timings= Timing output formats (unstable) (comma separated): html, json Feature Selection: -F, --features Space or comma separated list of features to activate --all-features Activate all available features --no-default-features Do not activate the `default` feature Manifest Options: -m, --manifest-path Path to Cargo.toml --frozen Require Cargo.lock and cache are up to date --locked Require Cargo.lock is up to date --offline Run without accessing the network