Skip to content

Commit 815b062

Browse files
committed
fix(wheels): link libstdc++ statically on manylinux1
For some reason, the ninja binary built on manylinux1 is segfaulting on ubuntu20.04+ & RHEL 8+. Statically linking libstdc++ fixes the issue.
1 parent c5a6e10 commit 815b062

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

pyproject.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,11 @@ repair-wheel-command = "python scripts/repair_wheel.py -w {dest_dir} {wheel}"
1717
test-extras = "test"
1818
test-command = "pytest {project}/tests"
1919

20-
[tool.cibuildwheel.linux]
20+
[[tool.cibuildwheel.overrides]]
21+
select = "*-manylinux_{x86_64,i686}"
2122
manylinux-x86_64-image = "manylinux1"
2223
manylinux-i686-image = "manylinux1"
24+
environment = { LDFLAGS = "-static-libstdc++" }
2325

2426
[tool.cibuildwheel.macos.environment]
2527
MACOSX_DEPLOYMENT_TARGET = "10.9"

0 commit comments

Comments
 (0)