Author Topic: cppcheck not working for latest version of codeblocks.  (Read 4164 times)

Offline rajin100000

  • Single posting newcomer
  • *
  • Posts: 9
cppcheck not working for latest version of codeblocks.
« on: July 07, 2021, 03:17:50 pm »
I downloaded Code::blocks 20.03 and I downloaded CppCheck 1.89 and then went to settings -> environment -> CppCheck and then I add "C:\Program Files\Cppcheck\cppcheck.exe" in the path. And when I use plugin -> cppcheck ... There was an error.

CppCheck Application: C:\Program Files\Cppcheck\cppcheck.exe
CppCheck Arguments: --verbose --enable=all --enable=style --xml
Platform: Windows 7 32 bit
Cppcheck Version: 1.89
Download link: https://sourceforge.net/projects/cppcheck/files/cppcheck/1.89/cppcheck-1.89-x86-Setup.msi/download
Code::blocks version: 20.03
Error message in CppCheck windows:
Code
Running cppcheck/vera++ analysis... please wait...
Switching working directory to : D:\Program1\C++\LearnCPP\demo1\
Executable cppcheck: 'C:\Program Files\Cppcheck\cppcheck.exe'.
Path to cppcheck: 'C:\Program Files\Cppcheck'.
Updated PATH environment to include path to cppcheck: 'C:\Program Files\Cppcheck' ('C:\Program Files\Cppcheck;D:\IDE\CodeBlocks\MinGW\bin;D:\IDE\CodeBlocks\MinGW;C:\Program Files\Common Files\Oracle\Java\javapath;C:\ProgramData\Oracle\Java\javapath;C:\Program Files\Intel\iCLS Client;C:\Windows\System32;C:\Windows;C:\Windows\System32\wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Program Files\Intel\OpenCL SDK\2.0\bin\x86;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\MiKTeX\miktex\bin;D:\CodeEditor\sublime_text_build_4107;D:\ConsoleEmulators\PortableGit\cmd;D:\Compilers-Interpreters\mingw-w64\i686-8.1.0-posix-dwarf-rt_v6-rev0\mingw32\bin').
C:\Program Files\Cppcheck\cppcheck.exe --version
Cppcheck 1.89
Executable cppcheck: 'C:\Program Files\Cppcheck\cppcheck.exe'.
Path to cppcheck: 'C:\Program Files\Cppcheck'.
Updated PATH environment to include path to cppcheck: 'C:\Program Files\Cppcheck' ('C:\Program Files\Cppcheck;D:\IDE\CodeBlocks\MinGW\bin;D:\IDE\CodeBlocks\MinGW;C:\Program Files\Common Files\Oracle\Java\javapath;C:\ProgramData\Oracle\Java\javapath;C:\Program Files\Intel\iCLS Client;C:\Windows\System32;C:\Windows;C:\Windows\System32\wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Program Files\Intel\OpenCL SDK\2.0\bin\x86;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\MiKTeX\miktex\bin;D:\CodeEditor\sublime_text_build_4107;D:\ConsoleEmulators\PortableGit\cmd;D:\Compilers-Interpreters\mingw-w64\i686-8.1.0-posix-dwarf-rt_v6-rev0\mingw32\bin').
C:\Program Files\Cppcheck\cppcheck.exe --verbose --enable=all --enable=style --xml --file-list=CppCheckInput.txt
Checking main.cpp ...
Defines:
Undefines:
Includes:
Platform:win32A
<?xml version="1.0" encoding="UTF-8"?>
<results version="2">
    <cppcheck version="1.89"/>
    <errors>
        <error id="missingIncludeSystem" severity="information" msg="Cppcheck cannot find all the include files (use --check-config for details)" verbose="Cppcheck cannot find all the include files. Cppcheck can check the code without the include files found. But the results will probably be more accurate if all the include files are found. Please check your project&apos;s include directories and add all of them as include directories for Cppcheck. To see what files Cppcheck cannot find use --check-config."/>
    </errors>
</results>
Cppcheck cannot find all the include files (use --check-config for details)
Code:
Code
#include <iostream>

void printValue(int value)
{
    std::cout << value;
}

int main()
{
    printValue(5);
    printValue(6);
    printValue(7);

    return 0;
}