Skip to content

Commit 0e1d4cd

Browse files
timsaucerclaude
andcommitted
build: enable PyO3 generate-import-lib for Windows free-threaded wheels
Windows free-threaded Python does not expose `abiflags` in sysconfig, so PyO3's default Windows linkage path fails with "A python 3 interpreter on Windows does not define abiflags in its sysconfig ಠ_ಠ" when building cp31Xt wheels. Enabling the `generate-import-lib` PyO3 feature switches Windows builds to a generated import library (provided by the `python3-dll-a` crate) that does not depend on a fully populated sysconfig. It is a no-op on macOS and Linux and is compatible with the existing `abi3` feature. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 770e1e8 commit 0e1d4cd

2 files changed

Lines changed: 11 additions & 1 deletion

File tree

Cargo.lock

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/core/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ tokio = { workspace = true, features = [
4040
"rt-multi-thread",
4141
"sync",
4242
] }
43-
pyo3 = { workspace = true, features = ["extension-module"] }
43+
pyo3 = { workspace = true, features = ["extension-module", "generate-import-lib"] }
4444
pyo3-async-runtimes = { workspace = true, features = ["tokio-runtime"] }
4545
pyo3-log = { workspace = true }
4646
chrono = { workspace = true }

0 commit comments

Comments
 (0)