This morning I received a new update from Apple for the Xcode commandline tools (version 7.3). After this update was installed, code that is using gcov crashes on exit when a program has loaded a library using dlopen(). The library that is opened using dlopen also has coverage reporting enabled. When I don't dlopen the library the crash doesn't occur.
The program crashes here:
llvm_writeout_files + 20
"llvm_writeout_files" is one of the functions that gets created when a program is using gcov. When code coverage is disabled, the error no longer occurs. I had no problems running with gcov before this update.
The issue can be reproduced with these steps:
git clone https://github.com/cortoproject/corto
rake <<build will fail>>
corto locate corto/gen/c/common <<application will crash>>
Anyone else experiencing similar issues?
Could you please let me know if you were able to fix the issue.