Commit Graph

15 Commits

Author SHA1 Message Date
mmooij 02c20b8e85 Check if sources/include are Nonde3 type 2018-08-21 17:52:09 +02:00
fedepell 6ce409f98f cppcheck: fix Python3 incompatibilities (see #1921) 2017-03-08 18:17:52 +01:00
Thomas Nagy 058b8f7f39
simplifications 2016-11-06 12:00:35 +01:00
Federico Pellegrin 90b66a4f04 cppcheck: fix extra forn multiple build rules are in a single wscript (#1844)
* cppcheck: fix extra forn multiple build rules are in a single wscript

When executed the output from cppcheck will be put inside cppcheck.xml and
then the generated error output inside cppcheck/index.html (and related
subfiles). Of course if two separate build rules are present the files
will clash with each other and data will be lost.

So this will not work in previous version:

bld.program(source=bld.path.ant_glob('src/ex-prog-*.cpp'), includes='src/', target='ex-prog-c')
bld.program(source=bld.path.ant_glob('src/ex-prog2-*.cpp'), includes='src/', target='ex-prog2-c')

In the output just one of the two results will be there (or in worst case
we will have files being deleted/garbled) as they both try to work on
cppcheck.xml and index.html (in build and build/cppcheck respectively)

With this commit the xml/html files have a reference to the task name (so
appended with a dash) so they are unique and don't clash. Also all the
messages to the user are corrected accordingly so the user is pointed to
the correct name of the file (and so are the internal links generated in
the html file).

In the previous case we will have:

ccpcheck detected (possible) problem(s) in task 'ex-prog2-c', see report for details:
    file:///home/fede/waf/cppc/build/cppcheck/index-ex-prog2-c.html

ccpcheck detected (possible) problem(s) in task 'ex-prog-c', see report for details:
    file:///home/fede/waf/cppc/build/cppcheck/index-ex-prog-c.html

* cppcheck: Provide as an option also old way of single index.html file for compatibility
2016-11-06 11:33:25 +01:00
fedepell 572cd98aab cppcheck: add possibility to use -j option for multiple parallel threads, speeds up drastically when executing on multiple source files 2016-11-03 22:02:10 +01:00
fedepell 655217384a cppcheck: check very ugly if code checking for configuration mode 2016-10-27 18:36:34 +02:00
fedepell c6ebd2547c cppcheck: do not execute task when in configuration mode as this can break other tools (ie qt5) which do a test build. see also #1840 2016-10-26 22:41:02 +02:00
Thomas Nagy 9332a9c24d Whitespace and Options.options for cppcheck 2016-07-25 20:18:49 +02:00
Thomas Nagy 67e7db41d9
Simplification x=x+1 -> x+=1 2016-05-22 00:45:47 +02:00
Thiago da Silva Andrade Soares =^.~= 4bea5a28ae Cppcheck tool - Fix creation of invalid command on windows
The following error occurring when we try to run the cppcheck tool on windows.
As we see in the error message, the command is not well formed.

WafError:
    Command "['C:\\\\Program Files (x86)\\\\Cppcheck\\\\cppcheck.exe'] --inconclusive --report-progress --verbose --xml ..."
returned 1
2016-02-24 21:53:15 +01:00
Thomas Nagy f28426594e
Cleanup: removed most unused variables and imports 2015-10-11 11:32:27 +02:00
Thomas Nagy 7cba550826
Fixed a few Python3 compatibility issues in extras modules 2015-09-27 16:09:21 +02:00
Thomas Nagy 80344dee5e
Use splitlines when possible 2015-03-03 12:19:25 +01:00
Thomas Nagy c705d019d1
Python3 syntax 2014-10-11 19:24:43 +02:00
Thomas Nagy 9838d0bb08 New cppckeck tool from Michel Mooij 2013-09-22 17:41:17 +02:00