$ show matthew-brett/delocate
Delocate is a macOS-specific tool for making Python wheels redistributable by bundling required dynamic libraries. It analyzes wheels to find external library dependencies, copies those libraries into the wheel, and updates install names and rpaths to use @loader_path references. The tool consists of a core library with a rich CLI interface providing commands like delocate-wheel, delocate-path, delocate-listdeps, and delocate-merge for combining wheels of different architectures. The architecture separates concerns into modules for dependency analysis (libsana), low-level Mach-O binary manipulation (tools), wheel-specific operations (wheeltools), and directory tree fusing (fuse).
The LLM identified 1 files worth highlighting for reuse:
Provides low-level utilities for inspecting and modifying Mach-O binaries on macOS. Handles complex tasks like parsing install names and IDs from otool output, managing rpaths, setting install IDs to be unique within Python space, dealing with codesigning requirements, and detecting architectures in fat binaries. This module is completely self-contained with no dependencies on other delocate modules, making it highly reusable for any project needing to work with Mach-O binaries.