-
Notifications
You must be signed in to change notification settings - Fork 147
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
feat: support setup helpers #60
Conversation
dc77f03
to
be446a1
Compare
@YannickJadoul, in cibuildwheel: pip wheel /project -w /tmp/cibuildwheel/built_wheel --no-deps Why (Looking at the docs, this seems correct, just slightly odd, unless the worry is that extra wheels will be placed in the final directory, but I think that can happen anyway. Might just chalk it up to another reason PEP 518 is better.) |
c54cdc7
to
3f76df9
Compare
As far as I know, When the created wheel gets tested with PyPI, |
Okay, but this a) breaks |
96b934d
to
ee6126f
Compare
Actions are not yet enabled in this repository? |
I've been building them locally. There might be a setting in the "actions" tab that @wjakob can set, otherwise, it might need to be merged first. I'll trigger a build in my fork again. |
Edit: no, I can see the Actions tab, so I think it has to be in this repo before it will build. |
Let's see when this is merged, then. I thought when Actions were enabled, things just started building when adding a workflow, but I might be mistaken. |
f06fd2c
to
ac9b93f
Compare
ac9b93f
to
435a2b6
Compare
9fb3bf9
to
5c8fb37
Compare
5c8fb37
to
eb018b9
Compare
65089a3
to
4527f0a
Compare
e947f35
to
26a0a17
Compare
26a0a17
to
8d45d9f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With the usual caveats (I don't know a lot about the details): this is a huge amount of work, going in a good direction, we can always fix details later.
Note that AppVeyor was completely broken
Sounds like it can only get better.
I'll probably refactor after this gets merged to use PEP 518, but for now, it is good to have this in the history,
I think that's a great plan.
@@ -1,5 +1,8 @@ | |||
#include <pybind11/pybind11.h> | |||
|
|||
#define STRINGIFY(x) #x | |||
#define MACRO_STRINGIFY(x) STRINGIFY(x) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I haven't come across this before ... why is the 2nd macro needed? Is this working around compiler bugs?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is an idiom if you need to stringify the contents post macro expansion. Just the first one would not expand the macro inside. It's BOOST_PP_STRINGIZE
, basically.
Okay, let's merge then cleanup as needed. :) |
Moving to the new setup helpers infrastructure being developed in pybind11 2.6.0. Adding cibuildwheel. Adding GHA checks.
There are three methods to use this; I'm using the setup_requires method; while this is discouraged,
it works just about everywhere(at least it does not require pip 10 like the PEP 518 method) and it's more complex than the PEP 518 method, which is basically just a simplification on this.I'll probably refactor after this gets merged to use PEP 518, but for now, it is good to have this in the history, and it would help to have an actual release of pybind11, since most of the work in the PR is getting pip to install from PyPI, which requires CMake and such. I've disabled Python 3.5 + Windows + cibuildwheel, since it does not correctly use PEP 518 due to "portable" install issues. It can handle PEP 518 only in the main project, not a dependency. (We could enable this by splitting the install into cmake first, then pybind11, but it won't matter once we use a released version, or even a beta version from PyPI).
Actions run can be seen here: https://github.com/henryiii/python_example/actions/runs/261642597
I've also added pip and conda builds to Actions; Travis should be able to be removed after this is merged, and appveyer reduced quite a bit. I don't have macOS & Windows conda builds running yet, due primarily to the fact it's hard to setup pybind11 from source since CMake isn't finding a valid compiler. As soon as we have (even a beta) release of pybind11, then it should be easy to add these back in (and simplify everything else). If we wanted to make it work, the conda-forge "compilers" package would probably set up the correct env variables for it to work.
Here's the contents of the file attached to the run (click "artifact" on that page to download):
Note that AppVeyor was completely broken; I've remove conda from it, and fixed it for pip builds.
May help #58 (might need support of minGW in setup helpers)
Closes #48
Closes #44
May help #35
Closes #23
May help #21
Closes #16