Skip to content

Fix setup.py to detect cross-compiling to ARM64 on Windows - #101

Open
maxbelanger wants to merge 1 commit into
python-cffi:mainfrom
maxbelanger:fix-win-arm64-cross
Open

Fix setup.py to detect cross-compiling to ARM64 on Windows#101
maxbelanger wants to merge 1 commit into
python-cffi:mainfrom
maxbelanger:fix-win-arm64-cross

Conversation

@maxbelanger

@maxbelanger maxbelanger commented Jul 26, 2024

Copy link
Copy Markdown
Contributor

We use cffi within a Windows application we cross-compile from x64 to arm64. In order to properly build cffi, we patch setup.py to detect VSCMD_ARG_TGT_ARCH. We're upstreaming this fix here in case it's helpful to others.

This was previously suggested by @zooba in an older issue. This is a technique also used by cibuildwheel and setuptools itself (pypa/setuptools#2724).

@maxbelanger maxbelanger changed the title make setup.py capable of detecting cross-compiling on windows when targeting arm64 Jul 26, 2024
@maxbelanger
maxbelanger marked this pull request as ready for review July 26, 2024 16:35
@arigo
arigo requested a review from nitzmahone July 26, 2024 16:38
@arigo

arigo commented Jul 26, 2024

Copy link
Copy Markdown
Contributor

@nitzmahone Matt, please merge this if it looks OK to you.

@nitzmahone

Copy link
Copy Markdown
Member

Wanted to get the existing 1.17.0 bits out there without making folks wait for an rc2, but this looks like a good candidate for a 1.17.1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants