[erlang-questions] Trace/BPT trap on OS X when loading linked-in driver

Max Lapshin max.lapshin@REDACTED
Tue Jun 21 19:54:36 CEST 2011

I've written linked-in driver for capturing sound with portaudio library.
When I load it, erlang exits with Trace/BPT trap message.

The following stacktrace in gdb:

#0  0x00007fff88d1f570 in __CFInitialize ()
#1  0x00007fff5fc0d5ce in
#2  0x00007fff5fc0d607 in
#3  0x00007fff5fc0bcec in

This happens because it is loading in non-main thread and CFInitialize
_must_ be called in main thread.


Is there any way to order erlang to load driver in main thread? Or
maybe there is some way to do workaround with some DYLD environment

More information about the erlang-questions mailing list