Page MenuHome

macOS/bpy: Fix error in builds with Address Sanitizer
AbandonedPublic

Authored by Ankit Meel (ankitm) on Apr 1 2021, 9:20 PM.

Details

Reviewers
None
Group Reviewers
Platform: macOS
Maniphest Tasks
T86579: macOS: improve bpy build system support
Summary
ERROR: Interceptors are not working. This may be because
AddressSanitizer is loaded too late (e.g. via dlopen). Please
launch the executable with:
DYLD_INSERT_LIBRARIES=/path/to/libclang_rt.asan_osx_dynamic.dylib
  • Find the real process running the scripts
  • Set it as the test runner python under certain conditions
  • Set the said environment variable
  • Print message with the command to run in case one wants to use it outside tests

Ref T86579

Diff Detail

Repository
rB Blender
Branch
asan_bpy (branched from master)
Build Status
Buildable 13858
Build 13858: arc lint + arc unit

Event Timeline

Ankit Meel (ankitm) requested review of this revision.Apr 1 2021, 9:20 PM
Ankit Meel (ankitm) created this revision.
  • Add comments, macro
Ankit Meel (ankitm) edited the summary of this revision. (Show Details)Apr 2 2021, 9:50 AM
Ankit Meel (ankitm) edited the summary of this revision. (Show Details)
Ankit Meel (ankitm) edited the summary of this revision. (Show Details)
Ankit Meel (ankitm) retitled this revision from WIP macOS/bpy: Fix error in builds with Address Sanitizer to macOS/bpy: Fix error in builds with Address Sanitizer.

I committed a simpler version of this patch. After rB2c23b4e0bff0: Python: on macOS, stop requiring framework for building bpy module it defaults to using Python from the precompiled libs where no extra code to detect the real Python exe is needed.

Maybe this will still fail when building Blender against a system Python install, though even that I could not reproduce and there's not really any reason to even do that. So not worth having this code complexity I think.