AnalyzerException raised during sonar-scanner on C++ files


I get an Exception while running sonar-scanner on a C++ projects built with Bazel and build-wrapper-linux-x86-64. Build-wrapper files are generated following instructions described here:

I can send the file in private.

Version used:
Ubuntu 18.04
Gcc 8.4.0
Bazel 4.0.0
CFamily plugin

Error observed:

com.sonar.cpp.analyzer.Analyzer$AnalyzerException: Exit code != 0: /srv/.cache/bazel/_bazel_root/6b2d616a82e3c53e2b731b04baf0fd17/execroot/binding/base/src/HeartBeat.cpp
at com.sonar.cpp.analyzer.Subprocess.execute(
at com.sonar.cpp.analyzer.Subprocess.execute(
at com.sonar.cpp.plugin.CFamilySensor.lambda$process$8(
at com.sonar.cpp.analyzer.AnalysisExecutor.lambda$submit$0(
at java.base/java.util.concurrent.Executors$ Source)
at java.base/ Source)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor$ Source)
at java.base/ Source)

Steps to reproduce:
launch sonar-scanner on the project.

Thank you,
Pierre Falez

Hi @pfalez ,

I sent you a PM.

Hi @pfalez ,

thank you for the reproducer, you are affected by CPP-2696, you can get over it by adding -DBOOST_ASIO_DISABLE_NOEXCEPT to your build.

Thank you ! Scan work fine now.


1 Like

Hi @pfalez ,

thank you for your notification!

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