Cppcheck : "Your Cppcheck installation is broken..." message

General questions regarding the usage of CodeLite
spert
CodeLite Curious
Posts: 6
Joined: Wed Feb 11, 2015 2:07 am
Genuine User: Yes
IDE Question: C++
Contact:

Cppcheck : "Your Cppcheck installation is broken..." message

Post by spert »

Hi,

I have following configuration:

Code: Select all

Windows 7, 64 bit
Codelite 7.0 64 Bit (installed from codelite-amd64-7.0.exe)
  installation dir: C:\Program Files\CodeLite ( I now added this to the PATH-environment-variable aswell)

In Codelite these are the Environment Variables:
CodeLiteDir="C:\Program Files\CodeLite"
UNIT_TEST_PP_SRC_DIR=C:\UnitTest++-1.3
WXWIN=c:\wxWidgets-3.0.2
WXCFG=gcc_dll\mswu
I have a problem when trying to run Cppcheck from the context menu on any project.

In the CppCheck-Tab I get following output:

Code: Select all

Starting cppcheck: "C:\Program Files\CodeLite\codelite_cppcheck.exe"  --enable=style  --enable=performance  --enable=portability  --enable=unusedFunction  --enable=missingInclude  --enable=information  --std=posix  --std=c99  --std=c++11 --force -j100 -IC:\cpp_projects\proc_space\game -IC:\cpp_projects\proc_space\game_libraries --suppress=missingIncludeSystem --template gcc  -I\cpp_projects\proc_space\game\ -I\cpp_projects\proc_space\game\ -I\dev_libs_cpp\SFML-2.2\include\ -I\cpp_projects\proc_space\game_libraries\ --file-list="C:\cpp_projects\proc_space\.codelite\cppcheck.list"
:: information: Failed to load std.cfg. Your Cppcheck installation is broken, please re-install. The Cppcheck binary was compiled with CFGDIR set to "config/cppcheck" and will therefore search for std.cfg in that path.
cppcheck: unusedFunction check can't be used with '-j' option. Disabling unusedFunction check.
===== cppcheck analysis ended. Found 0 possible errors=====
When I try to run the same command (copy & paste)

Code: Select all

C:\cpp_projects\proc_space\game>"C:\Program Files\CodeLite\codelite_cppcheck.exe"  --enable=style  --enable=performance  --enable=portability  --enabl
e=unusedFunction  --enable=missingInclude  --enable=information  --std=posix  --std=c99  --std=c++11 --force -j100--check-config  --suppress=missingIn
cludeSystem --template gcc  -I\cpp_projects\proc_space\game\ -I\cpp_projects\proc_space\game\ -I\dev_libs_cpp\SFML-2.2\include\ -I\cpp_projects\proc_s
pace\game_libraries\ --file-list="C:\cpp_projects\proc_space\.codelite\cppcheck.list"
cppcheck: unusedFunction check can't be used with '-j' option. Disabling unusedFunction check.
:: information: Failed to load std.cfg. Your Cppcheck installation is broken, please re-install. The Cppcheck binary was compiled with CFGDIR set to "
config/cppcheck" and will therefore search for std.cfg in that path.

C:\cpp_projects\proc_space\game>
I get basically the same error.

When I run the same command in the Codelite folder I get following message:

Code: Select all

C:\Program Files\CodeLite>"C:\Program Files\CodeLite\codelite_cppcheck.exe"  --enable=style  --enable=performance  --enable=portability  --enable=unus
edFunction  --enable=missingInclude  --enable=information  --std=posix  --std=c99  --std=c++11 --force -j100 -IC:\cpp_projects\proc_space\game -IC:\cp
p_projects\proc_space\game_libraries --suppress=missingIncludeSystem --template gcc  -I\cpp_projects\proc_space\game\ -I\cpp_projects\proc_space\game\
 -I\dev_libs_cpp\SFML-2.2\include\ -I\cpp_projects\proc_space\game_libraries\ --file-list="C:\cpp_projects\proc_space\.codelite\cppcheck.list"
cppcheck: unusedFunction check can't be used with '-j' option. Disabling unusedFunction check.
Checking C:\cpp_projects\proc_space\game\Game.cpp...
Checking C:\cpp_projects\proc_space\game\main.cpp...
#### .
ThreadExecutor::check wait failed, result: 4294967295 error: 87

C:\Program Files\CodeLite>

The cppcheck.list file contains following lines:

Code: Select all

C:\cpp_projects\proc_space\game\main.cpp
C:\cpp_projects\proc_space\game\Game.cpp
Allright... maybe it is my installation... I uninstalled Codelite and downloaded the same installer. This time I installed it to c:\CodeLite\ (I also changed my PATH-env. entry to that and also the Codelite internal env. variable I set to that directory).

When I right click on a project in my workspace inside codelite and choose the cppcheck I get following message:

Code: Select all

Starting cppcheck: C:\CodeLite\codelite_cppcheck.exe  --enable=style  --enable=performance  --enable=portability  --enable=unusedFunction  --enable=missingInclude  --enable=information  --std=posix  --std=c99  --std=c++11 --force -j100 -IC:\cpp_projects\proc_space\game -IC:\cpp_projects\proc_space\game_libraries --suppress=missingIncludeSystem --template gcc  -I\cpp_projects\proc_space\game\ -I\cpp_projects\proc_space\game\ -I\dev_libs_cpp\SFML-2.2\include\ -I\cpp_projects\proc_space\game_libraries\ --file-list="C:\cpp_projects\proc_space\.codelite\cppcheck.list"
:: information: Failed to load std.cfg. Your Cppcheck installation is broken, please re-install. The Cppcheck binary was compiled with CFGDIR set to "config/cppcheck" and will therefore search for std.cfg in that path.
cppcheck: unusedFunction check can't be used with '-j' option. Disabling unusedFunction check.
===== cppcheck analysis ended. Found 0 possible errors=====
and the config file std.cfg (xml format) exists in c:\CodeLite\config\cppcheck

Have you encountered this kind of issue before?

How did you solve it?

Could it be again a silly mistake I made?

Thanks for your help!
User avatar
eranif
CodeLite Plugin
Posts: 6372
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Cppcheck : "Your Cppcheck installation is broken..." mes

Post by eranif »

Can you please post this as bug in GitHub?

Eran
Make sure you have read the HOW TO POST thread
spert
CodeLite Curious
Posts: 6
Joined: Wed Feb 11, 2015 2:07 am
Genuine User: Yes
IDE Question: C++
Contact:

Re: Cppcheck : "Your Cppcheck installation is broken..." mes

Post by spert »

Hi Eran,

Thanks for your reply.

After your reply I started experimenting some more...

on a separate computer:
I have a separate computer (also Windows 7 , 64 bits) where I had installed Codelite 6.1.1 (32 bit version).

I checked with a project I have there if the cppcheck works. It works normally.

Then I installed Codelite 7.0 (installer, 32 bit version ) , preserving user settings.

Cppcheck still worked fine there.

I then uninstalled Codelite (without removing user settings).

I installed Codelite 7.0 (installer, 64 bit version) , preserving user settings.

I tried again and it still worked fine.

Then I remembered the setting you gave me to solve the clang error I had when I asked about a different problem ( Issue 643 in github ) a few days ago . On this machine I didn't set the "double quote wrapper for windows" option in (Editor Settings-Terminal). After activating the setting I got the same kind of error on this computer for cppcheck I have on my other machine. After removing the option I still had this problem. It seems somehow as if setting the "double quote wrapper for windows" option stays for cppcheck even after unsetting it.
I will create a new issue on Github tomorrow evening ( providing more structured information ) after some more tests.
I need to rest now.
Good night and thanks!
Timo
spert
CodeLite Curious
Posts: 6
Joined: Wed Feb 11, 2015 2:07 am
Genuine User: Yes
IDE Question: C++
Contact:

Re: Cppcheck : "Your Cppcheck installation is broken..." mes

Post by spert »

Hi,

I created a new issue : #668 .

Thanks .

Timo
coot
CodeLite Enthusiast
Posts: 20
Joined: Thu Jun 15, 2017 1:41 pm
Genuine User: Yes
IDE Question: c++
Contact:

Re: Cppcheck : "Your Cppcheck installation is broken..." mes

Post by coot »

I encountered this issue again. on CodeLite 10.0.0.5
In CMD, trying following command will got the same error. always failed to load std.cfg. However this cfg file exists in config/cppcheck.

Code: Select all

Starting cppcheck: C:\Windows\system32\cmd.exe /C D:\CodeLite\codelite_cppcheck.exe  --enable=style  --enable=performance  --enable=portability  --enable=unusedFunction  --enable=missingInclude  --enable=information  --std=posix  --std=c++11  --template gcc  --file-list=D:\Projects\QA_TestFramework\.codelite\cppcheck.list 
:: information: Failed to load std.cfg. Your Cppcheck installation is broken, please re-install. The Cppcheck binary was compiled with CFGDIR set to "config/cppcheck" and will therefore search for std.cfg in that path.
===== cppcheck analysis ended. Found 0 possible errors=====
User avatar
eranif
CodeLite Plugin
Posts: 6372
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Cppcheck : "Your Cppcheck installation is broken..." mes

Post by eranif »

Thanks, please open a bug for this on GitHub
Make sure you have read the HOW TO POST thread
User avatar
eranif
CodeLite Plugin
Posts: 6372
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Cppcheck : "Your Cppcheck installation is broken..." mes

Post by eranif »

nvm, already fixed this.
The fix will be part of CodeLite 10.0.6 (hopefully, this weekend)

Thanks for reporting this
Make sure you have read the HOW TO POST thread
coot
CodeLite Enthusiast
Posts: 20
Joined: Thu Jun 15, 2017 1:41 pm
Genuine User: Yes
IDE Question: c++
Contact:

Re: Cppcheck : "Your Cppcheck installation is broken..." mes

Post by coot »

:) OK, I will try it then.
coot
CodeLite Enthusiast
Posts: 20
Joined: Thu Jun 15, 2017 1:41 pm
Genuine User: Yes
IDE Question: c++
Contact:

Re: Cppcheck : "Your Cppcheck installation is broken..." mes

Post by coot »

Solved in 10.0.0.6 :D
Post Reply