Skip to content

Add an option to include debug information in the Python executable and shared libraries in MacOS #95973

Open
@pablogsal

Description

@pablogsal

Because MacOS likes to do things differently, the DWARF debugging information is not included by default in the final executables and shared libraries. Instead, MacOS has a separate linker dsymutil that can link this information in the final binary. Because by default nobody is doing this, all the python installations in MacOS have no debug information at all making debuggers like lldb almost useless.

To solve this problem, add a new --with-dsymutil configure option that ensures that we package the debug information inside. In my M1 macos this makes the Python executable 0.2M bigger.

We should maybe discuss if we want to activate this by default.

Metadata

Metadata

Labels

buildThe build process and cross-build

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions