codechecker
codechecker copied to clipboard
Cannot store reports with relative include paths: If the clang-tidy report refers to relative paths the resulting plist contains invalid absolute filepath
This error prevents storing the results.
The problem can be reproduced like this:
In the original compiler call the header was included like this:
clang .. -include ../../../Sources/some_header.hpp
the clang-tidy textual output:
gtest_pred_impl.h:40:10: warning: circular header file dependency detected while including 'gte
st.h', please check the include path [misc-header-include-cycle]
40 | #include "gtest/gtest.h"
| ^
/Users/dkrupp.ext/CCMain/Bin.MacARM/Modules_LLVM_4_0_64.dev/GoogleTest/gtest/gtest.h:388:10: note: 'gtest_pred_impl.h' included from here
388 | #include "gtest/gtest_pred_impl.h"
| ^
**./../../../Sources/some_header.hpp:66:10: note: 'gtest.h' included from here**
66 | #include "gtest/gtest.h"
./../../../Sources/some_header.hpp:66:10: note: 'gtest.h' included from here
In the plist file the file section some_header.hpp is referred to as:
</array>
<key>files</key>
<array>
<string>/Sources/some_header.hpp</string>
I couldn't reproduce this issue. All clang-tidy versions I tried are emitting absolute source patsh. Could you, please, check this reproducer again and attach the source files and exact commands you run? Thank you!