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

build arm64 wheels on windows #43

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

build arm64 wheels on windows #43

wants to merge 3 commits into from

Conversation

wjakob
Copy link
Owner

@wjakob wjakob commented Mar 19, 2024

No description provided.

@wjakob
Copy link
Owner Author

wjakob commented Mar 19, 2024

@henryiii I don't think this worked following the change to give precedence to SKBUILD_SOABI and SKBUILD_SOSABI in nanobind. Looking into the transcript for the windows-latest arm64 builds, the generated shared libraries have amd64 in their filename.

@wjakob
Copy link
Owner Author

wjakob commented Mar 19, 2024

Another unrelated question: CIBW generates a warning about arm64 Python 3.8 wheels (which I think should probably be removed from the build matrix in any case, that's a weird combination). Attempting to do so within pyproject.toml did not seem to do anything: https://github.com/wjakob/nanobind_example/blob/master/pyproject.toml#L41. Did I get something wrong?

@henryiii
Copy link
Contributor

No colon, that's only for tests - universal wheels needed a way to skip the either of the two possibilities when testing, so there's a colon for test-skip (and only for universal wheels). If you want to silence the warning, then you should use test-skip. 3.8 was rather important for macOS Apple Silicon, as it was the default version installed for quite a while (still?). But it's barely supported officially, so it's a little tricky to build for it.

I'll look at the issue soon, currently on paternity leave so am a bit slow.

@henryiii
Copy link
Contributor

Could you add:

[tool.scikit-build]
cmake.verbose = true
logging.level = "INFO"

So we can see a bit more about what's happening?

@wjakob
Copy link
Owner Author

wjakob commented Mar 19, 2024

done.

@henryiii
Copy link
Contributor

It won’t build with conflicts, unfortunately.

@wjakob
Copy link
Owner Author

wjakob commented Mar 20, 2024

oops, rebased.

pyproject.toml Outdated
@@ -29,6 +30,9 @@ build-dir = "build/{wheel_tag}"
# Build stable ABI wheels for CPython 3.12+
wheel.py-api = "cp312"

cmake.verbose = true
logging.level = "INFO"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
logging.level = "INFO"
logging.level = "DEBUG"

Sorry, a bit more info would be helpful.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No worries, I committed this change just now.

Copy link
Owner Author

@wjakob wjakob Apr 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@henryiii did the more detailed log message offer any useful info?

@henryiii
Copy link
Contributor

henryiii commented Apr 2, 2024

Yes, looks like a bug on my end:

    2024-03-21 14:54:34,003 - scikit_build_core - DEBUG - Windows ARM targeted via SETUPTOOLS_EXT_SUFFIX
    2024-03-21 14:54:34,003 - scikit_build_core - INFO - Reading DIST_EXTRA_CONFIG:build_ext.library_dirs=C:\Users\runneradmin\AppData\Local\pypa\cibuildwheel\Cache\nuget-cpython\pythonarm64.3.11.8\tools\libs
...
set(SKBUILD_SOABI [===[cp311-win_arm64]===] CACHE STRING "" FORCE)

Also, I want to look at pybind/pybind11#5083; the official word from FindPython is you shouldn't find_python(... Interpreter) when cross-compiling; if you don't, then you can set some of these values. But I do need to fix the bug first.

@henryiii
Copy link
Contributor

henryiii commented Apr 5, 2024

No, wait, that does say arm. Not sure why I thought it said amd or something. But I think that's the wrong form, I think it should be cpython-312-win_arm64.

@wjakob
Copy link
Owner Author

wjakob commented Jun 12, 2024

@henryiii does anything change here now that we have arm64 windows builders? (https://github.blog/2024-06-03-arm64-on-github-actions-powering-faster-more-efficient-build-systems/)

@henryiii
Copy link
Contributor

Wow, I knew the linux ones were coming, a bit of a surprise the Windows ones came too. That’s great. Going to be a little tricky to test though until open source ones are available (“by end of year”).

I can do some extra testing on my local windows arm machine, but I think everything should just work if you’re not cross compiling.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants