You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
MRG: Allow for delocating top level modules.
This delocates libraries into one directory per wheel. I've added a top-level package-less wheel to test with.
Prevents copying duplicate libraries when a wheel has multiple packages. Fixes#35.
Fixes issues where the module to work on is at the top-level, such as a wheel with no packages. Generally any current issue where delocate mysteriously doesn't bundle libraries has been fixed. Fixes#72, fixes#22, fixes#45, fixes#63, fixes#121, fixes#66, fixes#49, fixes#67.
See `_decide_dylib_bundle_directory` for how the folder to use is determined. I've followed the advice from #72 to use an auditwheel-style name. Wheels without packages use the folder `{package_name}.dylibs`, wheels with packages will put a `.dylibs` folder in only one of the packages preferring the one that matches the wheel name. The one directory will hold the dependencies of the entire wheel.
After that the fix was simple: In `delocate_wheel` call `delocate_path` only once and call it with a `tree_path` that includes the entire wheel.
Since this always collects everything regardless of if a package is found or not. This will also resolve issues where namespace packages couldn't be delocated. Fixes#95.
Repro (Attempting to build a wheel for protobuf)
git clone [email protected]:protocolbuffers/protobuf.git
cd protobuf
./autogen.sh
CXXFLAGS="-fPIC -g -O2" ./configure
make -j8
cd python
python setup.py bdist_wheel --cpp_implementation
delocate-listdeps --depending --all dist/protobuf-3.14.0-cp36-cp36m-macosx_10_15_x86_64.whl
delocate-wheel -w fixed_wheels -v dist/protobuf-3.14.0-cp36-cp36m-macosx_10_15_x86_64.whl
delocate-listdeps --depending --all dist/protobuf-3.14.0-cp36-cp36m-macosx_10_15_x86_64.whl
Note that the wheel has not been fixed.
If you modify
setup.py
and removenamespace_packages
this work correctly.I'm unsure if this is just another manifestation of #45
The text was updated successfully, but these errors were encountered: