hi all,
i'm currently facing a heap curruption in one of our externals, that appears (until now ;-)) only on macOS.
so i'd like to run with through the debugger of choice, which i figure is 'lldb'.
unfortunately, the system doesn't allow me to attach the debugger to the process, instead I get (in the Console.app):
default 19:02:06.024688+0200 kernel macOSTaskPolicy:
(com.apple.debugserver) may not get the task control port of (pd) (pid: 30725): (pd) is hardened, (pd) doesn't have get-task-allow, (com.apple.debugserver) is a declared debugger(com.apple.debugserver) is not a declared read-only debugger
now i'm not really knowledgable on macOS, so i've tried to run the script at [1] to add the "get-task-allow" entitlement, and now i get:
``` $ codesign -d --entitlements - Pd.app [Key] com.apple.security.get-task-allow [Value] [Bool] true ```
however, lldb still refuses to attach to the process.
the Pd is the one from millers homepage (I'd rather not compile it myself on that machine).
the external itself dlopen()s another library which depends on a couple of libs (all that is optional, and the dlopen()end library has been removed for debugging purposes). however, because of the dlopen() (and because we can), the external itself is also codesigned (but has no entitlements; dunno whether this is even possible with a single binary outside of a bundle)
any ideas?
ga,msdr IOhannes
[1] https://gist.github.com/talaviram/1f21e141a137744c89e81b58f73e23c3