Sonarqube Jenkins plug-in scan did not manage to pick up any file for scanning

We are using Sonarqube Jenkins plug-in to perform code scan. We encountered the problem in which the scan is run successfully, able to detect the compilation database JSON but zero file analyzed.

  • Jenkins version: 2.303.2
  • SonarQube Scanner for Jenkins: 2.14
  • Jenkins slave node OS: Linux
  • Sonarqube host is using Developer edition : version 9.0

A bit of background:
Our C language software uses a ESP32 related compiler which Sonarqube build wrapper does not support. As such, we tried using the Compilation Database approach. We used Bear tool to generate the Compilation Database JSON file ( We could not use CMAKE )

We setup the Sonarqube on our Jenkins (using Jenkins Sonarqube plug-in) and perform the scanning on the same Jenkins workspace in which we build our software. However, we got the following error as shown below in picture, indicating 0 files analyzed.

Interestingly, when we installed the community version locally in the same PC where the source code resides and perform scan using the same Compilation Database file residing in the same machine, it works.

Appreciate if anyone could advise what may need to be tweaked in order to get the Sonar working. Thanks

Hi @sgbrt-ckkoh ,

If the compiler is not in the list of supported compilers, the Compilation Database doesn’t solve the issue, the analyzer is going to ignore unknown compilers.

The community edition doesn’t have the C and C++ analyzer, the configuration properties are simply ignored.

Thanks for your reply.

Based on the information above in Sonarqube website C/C++/Objective-C | SonarQube Docs , we presume that Compilation Database would be the option to pursue for build system not supported by Build Wrapper.

Hi @sgbrt-ckkoh ,

in the reasons to use the Compilation Database, there is no reference to the compiler, only to the build system.

At the beginning of the documentation page, you have the list of supported compilers.