Sonar-scanner: The Compilation Database JSON file was found but 0 C/C++/Objective-C files were analy

Must-share information (formatted with Markdown):

  • sonar-scanner-cli-
  • SonarQube cloud LTS9.9
  • what are you trying to achieve: I tried to analyze C language files with sonar-scanner
  • what have you tried so far to achieve this: The compiler (ccblkfn.exe from Analog Devices) used in my project is not officially supported by SonarQube. So as recommended, I manually created a compile_commands.json file with detailed compilation information. I saved this file together with a file in the root directory of my project and executed “sonar-scanner.bat -Dsonar.login=Mycredential” command. After a while of execution, I got the following results:
16:25:04.641 ERROR: Error during SonarScanner execution
java.lang.IllegalStateException: The Compilation Database JSON file was found but 0 C/C++/Objective-C files were analyzed. Please make sure that:
  * you are correctly invoking the scanner with correct configuration
  * your compiler is supported
  * you are providing the path to the correct Compilation Database JSON
  * you are building and analyzing the same source checkout, absolute paths must be identical in build and analysis steps
        at com.sonar.cpp.plugin.CFamilySensor.process(
        at com.sonar.cpp.plugin.CFamilySensor.execute(
        at org.sonar.scanner.sensor.AbstractSensorWrapper.analyse(

I don’t know how to debug this problem. According to my understanding, compilation database is the method for C compilers which are not supported by sonar-build-wrapper. Does the error message mean that this compilation database method is not possible?
Could you please kindly help? Thanks in advance.
Do not share screenshots of logs – share the text itself (bonus points for being well-formatted)!

Hi @jiaoli ,

The compiler you are using is currently not supported, this is the related ticket: [CPP-3477] - Jira. Even by using the compilation database, you won’t be able to analyze your project. Would you be able to build your project with one of the supported compilers?

Hi, Massimo,

Thanks for your reply.

I read from the product roadmap of SonarQube that CCES compiler is planned to be supported ( This was planned in November 2021. Is there any planned date for this implementation? Thanks.

Hello @jiaoli
Let me chime in here.
The page you mention is to collect interest (“under consideration” tab).
At this stage, there is no decision taken about implementing support for CCES.
That being said, we take note of your interest.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.