# macOS Sonoma (ld64 from Xcode 15+) requires the combined form of the
# dynamic_lookup linker flag. Without this, PyO3 extension modules fail to
# link because Python C API symbols are resolved at runtime by the interpreter.
[target.aarch64-apple-darwin]
rustflags = ["-C", "link-arg=-Wl,-undefined,dynamic_lookup"]

# Same fix for x86_64 macOS (Intel Macs / Rosetta runners)
[target.x86_64-apple-darwin]
rustflags = ["-C", "link-arg=-Wl,-undefined,dynamic_lookup"]
