The CMAKE_C_COMPILER: pathto/qcc is not a full path to an existing compiler tool


I am trying to compile source code in windows environment using qcc compiler and facing this below error.
– The C compiler identification is QCC 5.4.0
CMake Error at CMakeLists.txt:22 (project):

C:/path to/qcc

is not a full path to an existing compiler tool.

Tell CMake where to find the compiler by setting either the environment
variable “CC” or the CMake cache entry CMAKE_C_COMPILER to the full path to
the compiler, or to the compiler name if it is in the PATH.
– Configuring incomplete, errors occurred!
See also “C:/Users/pramod.kumar4/Desktop/libwebsockets_build/libwebsockets-4.0-stable/CMakeFiles/CMakeOutput.log”.

I had created the CC environment variable and set the compiler path. Also tried setting the macro CMAKE_C_COMPILER before project() in CMakeLists.txt file.
But still facing same issue.

Windows executables end in “.exe”. It looks like you may be running a Windows CMake in a MINGW shell; where the shell doesn’t need to include the .exe to run the executable.

I’ve run into something like this before. When you specify the compiler you need to include the file extension. E.g. qcc.exe