Java 11.0.3 AdoptOpenJDK (64-bit)
Windows 10 10.0 amd64
build-wrapper, version 6.9 (win-x86-64)
We’re using National Instrument LabWindows/CVI to write and build our code
When running the sonar-scanner i get the:
java.lang.IllegalStateException: The “build-wrapper-dump.json” file was found but 0 C/C++/Objective-C files were analyzed.
We use this command in order to do the build:
build-wrapper-win-x86-64.exe --out-dir build_wrapper_output_directory “C:\Program Files (x86)\National Instruments\CVI2017\compile.exe” TestSuite_SVS350.prj -release
I can see from the log that the files is listed in dump.json as well in sonar-scanner util, but the program still says that 0 files where analyzed. Is it because we’re using National instruments compile.exe and that it’s the issue or is it something else that I’m missing? From the dump file I can se that the compile.exe is using clang in order to do the compiling though so I’m hoping that there could be something else that cause the issue.
I have zipped the logs but would prefer to send them in private message.
you can see the list of supported compilers in the product page: Code Quality and Code Security for C | SonarSource.
Could you mention precisely the compiler you are using so I can log a ticket on our side to add support for it?
It would be good to have it too, I am sending you a PM.
It’s using Clang 3.3 so should be supported from your site. But again, we are not calling it directly but though an executable from National instruments
in that case it may due to a misconfiguration, I am going to have a look at your log files.
as you can see in
build-wrapper-dump.json file there are many clang compiler invocation entries. However they are call to the frontend, you can notice the
-cc1. On the analyzer side we skip the calls to the frontend, we only look at compiler driver calls, this explains why none of the files is analyzed and you get the error.
Okay, thank you for your explanation. Just to be sure that I understand the situation correctly, we’re not able to use the wrapper when using the labwindows/cvi programmer? But we need to compile the code ourselves in order to use the wrapper.
correct, I created a ticket to track your report CPP-2555.
If you build your code calling
clang directly it would indeed work.