support binary wheels#388
Merged
pstradomski merged 3 commits intobazel-contrib:masterfrom Jan 7, 2021
Merged
Conversation
Contributor
|
How does this interact with target platform specification? Also, how does one even build a extension library in bazel? |
Contributor
Author
|
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 |
Contributor
|
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
|
Contributor
Author
|
Sure, done. |
hrfuller
reviewed
Dec 9, 2020
Contributor
hrfuller
left a comment
There was a problem hiding this comment.
Change looks good to me. A test would be nice!
Contributor
|
Do you plan to continue working on this PR? |
Also allow other Python tag specifiers like cp35, to constrain to a particular Python version.
Contributor
Author
|
I've added a test, and this should be good to go - it's been running fine here for the last month or so. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
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