-
Notifications
You must be signed in to change notification settings - Fork 770
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
Implement Basic Cross Compile Support #327
Conversation
Thanks! |
I think the comment for |
Thanks! |
Thank you for your pull request!
As far as I can see, the only mandatory information from the header files is the major and the minor version. Would it be possible to pass the major and minor version through environment variables or features, so you wouldn't even need to have the python version installed to build a native module? This is nothing I expect you to implement, but something that could be very useful even for same-platform compilation. |
As for:
There are other important pieces of information that are parsed out of |
Python 2 there are actually two versions
For bin crates, yes, but afaik not for cdylibs. My thought was mostly that it would be super useful if you could build wheels for all supported versions without having to install all those python versions, but then again I'm pretty happy if we get proper cross compilation support for installed interpreters. |
5f7bf37
to
d3bb75e
Compare
@konstin this should be good to go. Tested fine on my end. |
Thank you! |
This PR implements basic cross compile support. When cross compiling, the target python interpreter cannot be invoked since it may be built for an incompatible architecture (e.g. an armv7 target on an x86_64 host). Instead, attempt to parse the target interpreters compilation options out of it's headers.