Open dm8tbr opened 6 years ago
I suspect the problem is that clang crashes while parsing the compilation database. Can you try running valgrind, this will probably show some more details about what pointer was invalid.
Can you also run clang-tidy with this compilation database, if it crashes too that would confirm my assumption:
clang-tidy -p /home/tbr/src/icecast /home/tbr/src/icecast/conftest
Can you paste what is the compilation database for the file conftest ? I have noticed that sometimes, empty file in the compilation database can cause problem.
You can use this line to remove the empty files and see if it fixes the problem
sed -i '/"file": ""/d' compile_commands.json
This might be caused by a bug in fake_compiler.sh that fails to parse the entry.
@dm8tbr Any news?
This had dropped off my radar, sorry. I now updated both icecast and woboq sources to latest master, rebuilt both properly.
It still segfaults right after starting. After I ran @ogoffart's sed one-liner output changed mildly, but it still crashes.
tbr@puck:~/src/woboq_codebrowser$ build/generator/codebrowser_generator -b ~/compile_commands.json -a -p icecast:/home/tbr/src/icecast -o testfoo
Skipping file not included by any project /dev/null
[2%] Processing /home/tbr/src/icecast/src/acl.c
Segmentation fault
Wanted to give this a spin and run it on the http://icecast.org codebase. Tried it both with clang 5.0.2 and 6.0.1 (Debian testing). json generated by help of
scripts/fake_compiler.sh
Let me know if you need additional information.