Skip to content
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

Option to strip binaries generated by auditwheel #63

Closed
EvenOldridge opened this issue Mar 22, 2017 · 6 comments · Fixed by #255
Closed

Option to strip binaries generated by auditwheel #63

EvenOldridge opened this issue Mar 22, 2017 · 6 comments · Fixed by #255

Comments

@EvenOldridge
Copy link

Auditwheel is a great tool and is used by a lot of common libraries to build their wheel packages. I'm most interested in numpy and they mentioned that they use this library to package their wheels. Unfortunately somewhere in their build process the binaries are modified by patchelf such that strip doesn't work.

Is it possible to add the option to strip binaries directly within the auditwheel process?

Stripped binaries are critical for deployment, particularly of lambda functions and I'm unable to do the strip myself once installed.

A lot of people would benefit from this change in terms of saved space in deployment.

@njsmith
Copy link
Member

njsmith commented Mar 22, 2017

It's definitely possible, but everyone involved in maintaining auditwheel is very busy with other things, so it's much more likely to happen if you can implement a patch.

@EvenOldridge
Copy link
Author

Hey @njsmith, Just noticed you're also who I talked to on the numpy side of this problem as well.

I took a look at the issue a little further and it seems like someone working on the patchelf repo has isolated the problem and figured out a fix. I don't think it's merged with master yet, but it's available here:
https://github.com/rpurdie/patchelf/tree/c4deb5e9e1ce9c98a48e0d5bb37d87739b8cfee4

I'm guessing you'll probably want to wait until it's committed before integrating it.

@njsmith
Copy link
Member

njsmith commented Mar 25, 2017

We've shipped a patched version of patchelf in the manylinux image before – patchelf upstream is unfortunately not very responsive. But someone would have to confirm that the fix in that PR actually solves the problem here, and then do the (not terribly huge) work to update the manylinux image to use that version of patchelf.

I'm not sure it's really worth it, given that the thing that will actually reduce the size of wheels in practice is if auditwheels starts stripping them, and that doesn't require any tricky changes to a tricky C++ program.

@ogrisel
Copy link
Contributor

ogrisel commented Mar 27, 2017

+1, it would be great if someone could take the time to use this patched version of patchelf to "auditwheel repair" a significant portion of the numpy / scipy stack packages to ensure that this won't introduce a regression.

@sciyoshi
Copy link

sciyoshi commented May 2, 2017

pypa/manylinux#109 updated the manylinux image to use latest patchelf, however I'm running into new issues with auditwheel not detecting dependencies correctly, perhaps #68

@tkelman
Copy link

tkelman commented Dec 1, 2017

If #68 was fixed, should this be possible now? Any guidance on the best place to start implementing this, if anyone has looked into it yet?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants