This would be a great feature, I like to build in a separate out directory and right now the dump files "pollutes" the source tree. Either a --dumpdir or a --dumpprefix flag would be very useful. Or maybe use the already existing --cppcheck-build-dir for this?
Thanks!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
is this when you use --dump or --addon ? I think recommendation should overall be to use --addon .
If --addon is used I think it would be preferable to use temporary files. I think I made a ticket but haven't had time to look into that yet.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi forum ,
I am currently using the following command
cppcheck --dump inverter.c
I see that the relative dumped file is generated in the same folder of the file inverter.c
How is possible to generate the dumped file in a different folder?
Please let me know .
Thanks
If addons are executed in the GUI we create the dump files in the cppcheck build dir.
However the cli does not do that. I think it's unfortunate. Will see what we can do about it.
This would be a great feature, I like to build in a separate
out
directory and right now the dump files "pollutes" the source tree. Either a--dumpdir
or a--dumpprefix
flag would be very useful. Or maybe use the already existing--cppcheck-build-dir
for this?Thanks!
is this when you use --dump or --addon ? I think recommendation should overall be to use --addon .
If --addon is used I think it would be preferable to use temporary files. I think I made a ticket but haven't had time to look into that yet.
With
--addon
together with--cppcheck-build-dir
it seem to be putting the dump files in the build folder.The only drawback I can see is that the folder structure is not preserved in the build-dir (i.e. all files ends up in the root).
Last edit: Mikael Heden 2025-02-05
We also encounter this issue in the addon Python tests. See https://trac.cppcheck.net/ticket/13366.