Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update cibuildwheel, pypy libzmq bundling #1931

Merged
merged 3 commits into from
Feb 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ jobs:
cibw:
build: "pp*"

- os: macos-11
- os: macos-13
name: mac-arm
cibw:
arch: universal2
Expand Down
7 changes: 0 additions & 7 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -164,10 +164,3 @@ manylinux-i686-image = "manylinux2010"

# note: manylinux_2_28 builds are added
# in .github/workflows/wheels.yml
[[tool.cibuildwheel.overrides]]
select = "pp*win*"
# pypy builds libzmq as an Extension,
# doesn't bundle dlls (requires separate vcredist install, as pypy itself seems to)
# bundling external libzmq doesn't seem to work
environment = { ZMQ_PREFIX = "" }
repair-wheel-command = ""
9 changes: 6 additions & 3 deletions tools/install_libzmq.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,16 @@ cd ..

which ldconfig && ldconfig || true

# make sure to find our libsodium
export PKG_CONFIG_PATH=$PREFIX/lib/pkgconfig

tar -xzf zeromq-${LIBZMQ_VERSION}.tar.gz
cd zeromq-${LIBZMQ_VERSION}
# avoid error on warning
export CXXFLAGS="-Wno-error ${CXXFLAGS:-}"

./configure --prefix="$PREFIX" --disable-perf --without-docs --enable-curve --with-libsodium --disable-libsodium_randombytes_close
make -j4
make install
./configure --prefix="$PREFIX" --disable-perf --without-docs --enable-curve --with-libsodium --disable-drafts --disable-libsodium_randombytes_close
make -j4 src/libzmq.la
make install-libLTLIBRARIES install-data

which ldconfig && ldconfig || true
19 changes: 9 additions & 10 deletions tools/test_wheel.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import os
import platform
import sys
from fnmatch import fnmatch

import pytest

Expand Down Expand Up @@ -43,16 +44,14 @@ def test_bundle_msvcp():
)
print(dlls)
# Is concrt140 needed? delvewheel doesn't detect it anymore
should_bundle = ["msvcp140.dll"]
vcruntime = "vcruntime140.dll"
# check for vcruntime?
should_bundle = ["msvcp140*.dll"]
shouldnt_bundle = []
if platform.python_implementation() == 'PyPy':
should_bundle = []
elif sys.version_info < (3, 10):
shouldnt_bundle.append(vcruntime)

for dll in shouldnt_bundle:
assert dll not in dlls
for pattern in shouldnt_bundle:
matched = [dll for dll in dlls if fnmatch(dll, pattern)]
assert not matched

for dll in should_bundle:
assert dll in dlls
for pattern in should_bundle:
matched = [dll for dll in dlls if fnmatch(dll, pattern)]
assert matched
4 changes: 2 additions & 2 deletions tools/wheel-requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
cibuildwheel==2.15.0
delvewheel==0.0.22; sys_platform == 'win32'
cibuildwheel==2.16.5
delvewheel==1.5.2; sys_platform == 'win32'
Loading