Using the VS Code SonarQube plugin this leaves NUL.o files once analyze is done on a file (but perhaps not always(?)). My guess is that this should be deletes automatically, but fails. Is there any fix or WA to get rid of this garbage?
We need to probe the compiler to know which set of macros are predefined, the size of built-in types, etc. When doing so, we call the compiler with, among other parameters, --output NUL. Normally, in Windows, NUL is a special device that can be used to discard any data written to it. i.e. there should be no file created!
It seems your version of the IAR compiler appends .o to the parameter we pass, so NUL.o is created, which we do not expect.
I had a quick look at their documentation and couldn’t see anything mentioned about the .o being now appended by default, so we will need to try to reproduce ourselves and see if this was changed and at what point.
Hello,
I’ve been in contact with IAR and it seams that this problem is related to Win11.
Using “–output NUL” will generate a NUL.o file with some ~900 byte size while using “–output NUL:” will generate a NUL-file with size 0. All this on Win11
I don’t have a Win10 here but was given a screenshot from IAR showing “-o NUL:” to work as expected (leaving nothing). -o and --output is the same option