Hi Julien, >> +First recommendation is to use exactly the same version in this page and >> provide >> +the same option to the build system, so that every Xen developer can >> reproduce >> +the same findings. > > I am not sure I agree. I think it is good that each developper use their own > version (so long it is supported), so they may be able to find issues that > may not appear with 2.7.
Yes I understand, but as Bertrand says, other version of this tool doesn’t work quite well. I agree that everyone should use their own version, but for the sake of reproducibility of the findings, I think we should have a common ground. The community can however propose from time to time to bump the version as long as we can say it works (maybe crossing the reports between cppcheck, eclair, other proprietary tools). > >> + >> +Install cppcheck in the system > > NIT: s/in/on/ I think. Sure will fix > >> +============================== >> + >> +Cppcheck can be retrieved from the github repository or by downloading the >> +tarball, the version tested so far is the 2.7: >> + >> + - https://github.com/danmar/cppcheck/tree/2.7 >> + - https://github.com/danmar/cppcheck/archive/2.7.tar.gz >> + >> +To compile and install it, here the complete command line: >> + >> +make MATCHCOMPILER=yes \ >> + FILESDIR=/usr/share/cppcheck \ >> + CFGDIR=/usr/share/cppcheck/cfg \ >> + HAVE_RULES=yes \ >> + CXXFLAGS="-O2 -DNDEBUG -Wall -Wno-sign-compare -Wno-unused-function" \ >> + install > > Let me start that I am not convinced that our documentation should explain > how to build cppcheck. > > But if that's desire, then I think you ought to explain why we need to update > CXXFLAGS (I would expect cppcheck to build everywhere without specifying > additional flags). Yes you are right, this is the recommended command line for building as in https://github.com/danmar/cppcheck/blob/main/readme.md section GNU make, I can add the source. My intention when writing this page was to have a common ground between Xen developers, so that if one day someone came up with a fix for something, we are able to reproduce the finding all together. Cheers, Luca > > Cheers, > > -- > Julien Grall
