We are using CMake 3.21 and Ninja 1.10.2 under Windows and Linux.
We are experimental using Intel oneApi icx compiler.
At the linking step we get a warning (Linux)
clang++: warning: argument unused during compilation: ‘-inline-level=0’ [-Wunused-command-line-argument]
After inspecting the Ninja file I found out that is set
FLAGS = compile flags
in the linking step. I think this is unnecessary, can this be disabled?
Where did you specify the -inline-level=0 compiler flag? CMAKE_CXX_FLAGS are used any time the CMAKE_CXX_COMPILER is called, even when used to drive linking. There are other ways to add compile-only flags, such as target_compile_options.