Sonar-scanner fails to scan stm32cubeide project C code

Im trying to ci-cd pipeline for sonarqube developer edition and GitLab.
Target project is stm32cubeide project with C code.
My .gitlab-ci.yml file has 4 stages like below.

** - get-sonar-binaries**
** - build**
** - sonarqube-check**
** - sonarqube-vulnerability-report**

get-sonar-binaries and build stage passed(success).
But while executing sonarqube-check, I got error message like this.

INFO: Sensor CFamily [cpp]

INFO: CFamily plugin version: 6.48.1.62610

INFO: Using build-wrapper output: /builds/Tucano/bw0.4-fcu/build/debug/build/build-wrapper-dump.json

INFO: Available processors: 2

INFO: Using 2 threads for analysis.

INFO: Found empty cache on server

WARN: Provided compiler is not compatible.

Invalid probe found, skip analysis of files: [/builds/Tucano/bw0.4-fcu/App/Src/timer_wrapper.c]

The compiler probe ‘stdout’ is expected to contain at least one’#define’ directive:

WARN: Provided compiler is not compatible.

Invalid probe found, skip analysis of files: [/builds/Tucano/bw0.4-fcu/App/Src/tlmcmd.c]

The compiler probe ‘stdout’ is expected to contain at least one’#define’ directive:

WARN: Provided compiler is not compatible.

Invalid probe found, skip analysis of files: [/builds/Tucano/bw0.4-fcu/App/Src/tpar.c]

The compiler probe ‘stdout’ is expected to contain at least one’#define’ directive:

WARN: Provided compiler is not compatible.

Invalid probe found, skip analysis of files: [/builds/Tucano/bw0.4-fcu/App/Src/uart_wrapper.c]

The compiler probe ‘stdout’ is expected to contain at least one’#define’ directive:

INFO: PCH: unique=0 use=0 (forceInclude=0,throughHeader=0,firstInclude=0) out of 0 (forceInclude=0,throughHeader=0)

INFO: Z3 refutation rate: 0 out of 0

INFO: SE: 0 out of 0

INFO: Subprocess(es) done in 58ms

INFO: 0/71 files marked as unchanged

INFO: Cache: 0/0 hits, 125 bytes

INFO: 0 compilation units analyzed

INFO: ------------------------------------------------------------------------

INFO: EXECUTION FAILURE

INFO: ------------------------------------------------------------------------

INFO: Total time: 33.673s

INFO: Final Memory: 33M/117M

INFO: ------------------------------------------------------------------------

ERROR: Error during SonarScanner execution

java.lang.IllegalStateException: The “build-wrapper-dump.json” file was found but 0 C/C++/Objective-C files were analyzed. Please make sure that:

  • you are using the latest version of the build-wrapper and the CFamily analyzer

  • you are correctly invoking the scanner with correct configuration

  • your compiler is supported

  • you are wrapping your build correctly

  • you are wrapping a full/clean build

  • you are providing the path to the correct build-wrapper output directory

  • you are building and analyzing the same source checkout, absolute paths must be identical in build and analysis steps

Please help me.
How should I configure for sonar scanner to scan embedded c project(stm32cubeide)?

Hey there.

Do you know what compiler is being used under the hood? What does your build command look like (that you are passing to the build-wrapper)?