[PATCH] D14629: [analyzer] Configuration file for scan-build.

Антон Ярцев via cfe-commits cfe-commits at lists.llvm.org
Thu Nov 12 15:47:32 PST 2015


ayartsev created this revision.
ayartsev added a reviewer: zaks.anna.
ayartsev added subscribers: jordan_rose, krememek, sylvestre.ledru, cfe-commits.

A simple INI configuration file for scan-build with options - aliases to scan-build command line arguments. This configuration file can be used to customize scan-build runs as it is done via command line. Options from this config are processed before any command line arguments so equivalent command line arguments passed to scan-build will overwrite values obtained from config. An order in which options are passed to scan-build is the same in which they occur in the config.
[[ https://llvm.org/bugs/show_bug.cgi?id=8203 | PR8203 ]] is related to the issue.
In the future I intend to use this config to also customize ccc/c++-analyzer script runs (to e.g pass special includes to Clang-analyzer, e.t.c).
Please review!

Currently looking through CMakeLists.txt in scan-build folder I do not exactly know where 'CommonStuff.pm' and 'scan-build.cfg' should be placed (BinFiles/LibexecFiles/ResourceFiles). Perhaps 'CommonStuff.pm' will go to the 'ResourceFiles' dir.
I am in favor of placing 'scan-build.cfg' to 'BinFiles' even bearing in mind hypothetical usage of this config by ccc/c++-analyzer scripts.

Tested the patch under Windows/Unix, any additional testing is appreciated!

http://reviews.llvm.org/D14629

Files:
  tools/scan-build/CommonStuff.pm
  tools/scan-build/scan-build
  tools/scan-build/scan-build.cfg

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D14629.40086.patch
Type: text/x-patch
Size: 9357 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20151112/deba807c/attachment.bin>


More information about the cfe-commits mailing list