support binary wheels #388
Open
Conversation
Also allow other Python tag specifiers like cp35, to constrain to a particular Python version.
|
How does this interact with target platform specification? Also, how does one even build a extension library in bazel? |
|
It's up to the caller to provide the correct platform: In Anki's case we are building a Python extension module using the Rust rules + the pyo3 crate, then renaming it to the appropriate filename for the platform: https://github.com/ankitects/anki/blob/c505894b88221e6d31ed1b7fdb3a5d835c4de83e/pylib/anki/BUILD.bazel#L45 |
|
Ah, the solution with select() is actually quite nice. Can you please add
it to the documentation as an example?
pon., 7 gru 2020 o 23:38 Damien Elmes <notifications@github.com> napisał(a):
… It's up to the caller to provide the correct platform:
https://github.com/ankitects/anki/blob/c505894b88221e6d31ed1b7fdb3a5d835c4de83e/pylib/anki/BUILD.bazel#L103
In Anki's case we are building a Python extension module using the Rust
rules + the pyo3 crate, then renaming it to the appropriate filename for
the platform:
https://github.com/ankitects/anki/blob/c505894b88221e6d31ed1b7fdb3a5d835c4de83e/pylib/anki/BUILD.bazel#L45
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#388 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AKU4J4LCWI3CJWDJ7ICXRV3STVKNZANCNFSM4UP22J4A>
.
--
Paweł Stradomski
|
|
Sure, done. |
|
LGTM |
|
Change looks good to me. A test would be nice! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.


Also allow other Python tag specifiers like cp35, as binary wheels
typically list their required Python versions in the filename.
Was successfully able to upload a binary wheel created with this to PyPI,
and install it with pip.
PR Checklist
Please check if your PR fulfills the following requirements:
.parfiles. See CONTRIBUTING.md for infoPR Type
What kind of change does this PR introduce?
What is the current behavior?
Currently the code refuses to build a binary wheel.
Issue Number: N/A
What is the new behavior?
It accepts platforms other than 'any'.
Does this PR introduce a breaking change?
Other information