pypa / cibuildwheel

🎡 Build Python wheels for all the platforms with minimal configuration.
https://cibuildwheel.pypa.io
Other
1.78k stars 227 forks source link

Remove build specific environment variables from the test environment #1863

Open mayeut opened 3 weeks ago

mayeut commented 3 weeks ago

Description

macOS builds are using multiple environment variables specific to the build environment: MACOSX_DEPLOYMENT_TARGET, _PYTHON_HOST_PLATFORM, ARCHFLAGS, SDKROOT

Those are propagated to the test environments. They should probably be removed from those.

see https://github.com/pypa/cibuildwheel/pull/1856#issuecomment-2156493426 and the 2 following comments for more context.

Build log

No response

CI config

No response

henryiii commented 3 weeks ago

While MACOSX_DEPLOYMENT_TARGET makes sense, the others might cause it to be harder to build wheels in the test step if wheels are missing from test dependencies. Not the best idea to build here, in general, but it may currently work because the correct variables are set for building.

mayeut commented 2 weeks ago

Maybe we should adapt them all then ?

If we're thinking that we might break some edge case that requires building from sources by removing any of those environment variable then IMHO we should update them all: