Setup problem for header files
I have an eclipse C++ project and a configuration for static analysis, I am able to use the configuration file to perform static analysis, and generate a Parasoft C++test Report.
However, when i export the configuration file and tried to perform static analysis via the command line (cpptestcli), I encountered setup problems.
/MyProject/Messages/MsgCtrl.cpp BugDetective checker: could not build analysis data File could not be successfully parsed: /MyProject/Messages/MsgCtrl.cpp c/c++ code checker: error during parsing file. /MyProject/Messages/MsgCtrl.cpp:8:40: fatal error: /MyProject/Messages/MsgCtrl.h no such file or directory #include <MsgCtrl.h> compilation terminated. Error preprocessing file "/MyProject/Messages/MsgCtrl.cpp" Process excited with code: 1 Error during parsing file : /MyProject/Messages/MsgCtrl.cpp
My folder structure
/home/user/MyWorkspace/MyProject MyProject |--- main.cpp |--- Messages |--- MsgCtrl.h |--- MsgCtrl.cpp
MsgCtrl.h and MsgCtrl.cpp are in the same folder. So if C++test can find the .cpp, why is it unable to find the .h file?
My cpptestcli command:
cd /home/user/MyWorkspace cpptestcli -data "../" -config "/home/user/MyWorkspace/myConfig.properties" -report "/home/user/MyWorkspace/Reports/MyProject.html" -resource "MyProject/" -nobuild