Skip to content

Commit 3f85c35

Browse files
committed
Link explicitly with libpython under Cygwin
As with native Windows Python, we need to explicitly link with libpython under Cygwin too. This fixes building extensions under Cygwin.
1 parent 493dd86 commit 3f85c35

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

newsfragments/5571.fixed.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fix linking with libpython under Cygwin

pyo3-build-config/src/impl_.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -890,6 +890,7 @@ pub fn is_linking_libpython_for_target(target: &Triple) -> bool {
890890
|| target.operating_system == OperatingSystem::Aix
891891
|| target.environment == Environment::Android
892892
|| target.environment == Environment::Androideabi
893+
|| target.operating_system == OperatingSystem::Cygwin
893894
|| !is_extension_module()
894895
}
895896

0 commit comments

Comments
 (0)