-
Notifications
You must be signed in to change notification settings - Fork 130
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
compare between mesonpy
and mesonpep517
python build backends
#271
Comments
mesonpy
and mesonpep517
python build backendsmesonpy
and mesonpep517
python build backends
We can't upload the binaries with mesonpep517, because we don't do the repair step. This leads to the situation that PyPi says The repair step doesn't work because mesonpep517 is not packaging up libnvme.so only the Python c binding library is in the dist package. There is also no way to workaround in tricking meson to install libnvme.so into the python side-config directory because config_settings is not supported in v0.2. And there was no release for over one year. I guess we can say this project is not ready for this tasks. mesonpy is not working either, at least not out of the box and I am running out of steam. I think we can't really upload precompiled binaries at this point. Uploading just the source code to PyPi is currently the only working solution I suppose. (I've spend way too much time today to figure this out.) |
And after playing with build_sdist, I found out that we have the exact problem described here: pybind/cmake_example#11 Basically, we would need to build libnvme as a static library and link it into the python binding library to get this working correctly. Unless you ask the user to install libnvme.so and then use pip to install the python binding. If the user already installed libnvme via a package manager, why not just not installing the Python binding as well via the same means. And it's not installed via a package manager instead via source, just let the user also install the binding in the same way. This seems all pretty much a big mess and I think at this point there is little point in trying to upload anything to PyPi. The Python binding to a shared library use case is not directly supported (which I do understand why) and can only make working with some serious workarounds. And I am not willing to invest the time to do this. First of, we would need to be able to build libnvme completely statically (not possible at this point, we are missing libuuid as wrap) and this needs to be linked into the Python binding library. I haven't seen any hooks how to do it or at least not with mesonpep517 v0.2. Given this, I am going to remove the whole PyPi integration attempt. If the upstream situation changes and all fits into place nicely I don't mind having it added back. But at it is right now, it's just not helping anyone. |
thanks @igaw indeed a lot o work you put into this and I put originally about the same amount of time |
So the only thing I am still pondering around, if uploading just the sdist would actually make sense nonetheless. I am sure we are not the only one in this situation. Are there any projects which just upload the Python binding? |
yes, I know many projects just upload sdist without |
Okay, I don't mind doing the sdist part. I thought it's not that useful. |
FWIW, I've uploaded the binding to PyPi manually (yeah, I know, sneaky thing...) but I wanted to get the project name claimed on PyPi before someone else is getting it. So the next release should work through the normal CI means. |
just FYI, just documenting here for later... once we come back to this problem... |
Yay. looks good ! https://pypi.org/project/libnvme/ |
I think the proper way is to get this kind of setup supported is to teach mesonpep517 to handle it internally. Having to maintain |
just for documentation this looks ok
|
Hmm, I see 'wheel'. Do we need to keep the wheel requeriment in pyproject.toml? |
non-no-no, this is excellent. Exactly as expected. |
yes, we can leave |
|
@eli-schwartz wow! Thanks for helping out. It was on my TODO list and even started with it but got nowhere... |
It is now merged upstream, please give it a try. |
something like this #349 ? not sure... |
Issue/reminder for myself @glimchb to learn more and compare:
The text was updated successfully, but these errors were encountered: