SonarLint unable to find any C++ headers

Hey!

Unfortunately, I don’t think I can share these logs. I collected them, but after looking over them they do expose a bunch of things about my employers code structure (understandably so).

So please bear with me as I try to extract useful information without actually sharing the logs directly :smiley:

The extraProperties tag in the analysis configuration JSON is pointing to a local path (/home/user/src/Repo/my/code/header.h), but all of the -I includes to the compiler are using the docker path (-I/app/Repo/my/code/).

We mount a folder above our repo into a docker container when we build (/home/user/src//app/). The CLion docker toolchain handles this for us (see here).

So it actually seems like the problem is a mismatch in local path input files but includes that use the docker path.

"cmd":[
"/usr/bin/g++",
"/home/user/src/Repo/my/code/header.h",
"-I/app/Repo/my/code/"
]

Should be easy to reproduce by just using the Docker Toolchain.