From f5522109200616fa7d32d1185ddfb6f2c46c67cc Mon Sep 17 00:00:00 2001 From: Jeremy Howard Date: Mon, 31 Aug 2026 09:25:02 +1000 Subject: [PATCH] Separate fast local and optimized distribution builds --- .github/workflows/ci.yml | 2 +- Cargo.toml | 17 +++++++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index afbc3ee..4b856aa 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -31,7 +31,7 @@ jobs: - uses: actions/checkout@v7 - uses: PyO3/maturin-action@v1 with: - args: --release --out dist -i python3.11 -i python3.12 -i python3.13 -i python3.14 + args: --profile dist --out dist -i python3.11 -i python3.12 -i python3.13 -i python3.14 manylinux: auto - uses: actions/upload-artifact@v7 with: diff --git a/Cargo.toml b/Cargo.toml index da1a529..6d5027d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,3 +17,20 @@ polling = "3" [features] python = ["dep:pyo3"] extension-module = ["python", "pyo3/extension-module"] + +[profile.release] +lto = false +codegen-units = 16 + +[profile.release.package.loopmini] +incremental = true + +[profile.dist] +inherits = "release" +lto = true +incremental = false +codegen-units = 1 +strip = true + +[profile.dist.package.loopmini] +incremental = false