I am using container image where I am trying to install the cppchecker using yum/apt-get but I am getting below message. How to use this software on linux machines?
apt-get install cppcheck
Reading package lists...
Building dependency tree...
Reading state information...
E: Unable to locate package cppcheck
Thanks,
Prasad.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Iam using python python:2.7.17 container available in dockerhub
that is probably pretty old.
Personally I would compile latest cppcheck. its quite easy. Example:
wget https://github.com/danmar/cppcheck/archive/refs/tags/2.9.tar.gz
tar xzvf 2.9.tar.gz
cd cppcheck-2.9
make MATCHCOMPILER=yes CXXFLAGS=-O2
=> you will get a cppcheck binary in current folder.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Though I used python:3.6 I am not able to get the latest version. I hope above steps works in this image and or they specific to any platform? I will try and let you know. Thank you for your assistance.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I want to ignore a specific directory while scanning the cpp files, how to ignore the directory? -i option is not working actually. Above make process worked for me.
Thanks
prasad.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi Team ,
I am using container image where I am trying to install the cppchecker using yum/apt-get but I am getting below message. How to use this software on linux machines?
Reading package lists...
Building dependency tree...
Reading state information...
E: Unable to locate package cppcheck
Thanks,
Prasad.
that is very strange. what specific distro do you use? is it some rare architecture?
does it help if you run apt-get update first?
Iam using python python:2.7.17 container available in dockerhub . I will try to do that apt-get update
Iam using python python:2.7.17 container available in dockerhub . I will try to do that apt-get update
it worked. I am getting 2.3 verison of cppcheck, how to get the latest version? How to use it from on ubuntu/linux https://github.com/danmar/cppcheck/releases/tag/2.9
that is probably pretty old.
Personally I would compile latest cppcheck. its quite easy. Example:
or use a later ubuntu image for cppcheck analysis
Though I used python:3.6 I am not able to get the latest version. I hope above steps works in this image and or they specific to any platform? I will try and let you know. Thank you for your assistance.
Hi Daniel Marjamäki,
I want to ignore a specific directory while scanning the cpp files, how to ignore the directory? -i option is not working actually. Above make process worked for me.
Thanks
prasad.