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

"usd_core-22.3-cp39-none-manylinux_2_17_x86_64" contains unstripped SO's #1814

Open
alexey-pelykh opened this issue Mar 25, 2022 · 5 comments

Comments

@alexey-pelykh
Copy link

alexey-pelykh commented Mar 25, 2022

Description of Issue

Shared libraries packaged into the bundle are too big because they are not stripped

Steps to Reproduce

  1. pip3.9 install usd-core
  2. Examine e.g. libusd_usd-*.so that is ~31.6Mb in size
  3. Run strip -s (or at least strip -S) on that file
  4. Observe it's being reduced to 10Mb in side

System Information (OS, Hardware)

Docker python:3.9-buster

Package Versions

22.3

Build Flags

No idea

@alexey-pelykh
Copy link
Author

Possibly

... auditwheel repair --strip ...

should do it 🤔

@alexey-pelykh
Copy link
Author

Nope, that does break it:

ImportError: /data/venv/lib/python3.9/site-packages/pxr/Tf/_tf.so: ELF load command address/offset not properly aligned

@alexey-pelykh
Copy link
Author

Using auditwheel 5.1.2 and patchelf 0.14.5 gives same result: or bloated libraries, or broken ones if stripped

@jilliene
Copy link

Filed as internal issue #USD-7293

@aganders3
Copy link

I was experiencing the same issue with a different package and changing auditwheel to batch the calls to patchelf fixed it for me. Now the wheel is much smaller (especially uncompressed) and stripping the libs does not cause the ELF load command address/offset not properly aligned error. I have a PR in for auditwheel here: pypa/auditwheel#376.

In the meantime you could try installing from my branch (https://github.com/aganders3/auditwheel/tree/aa/batch-patch) and using auditwheel repair --strip.

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

No branches or pull requests

3 participants