[PATCH] scan-build to accept all "-isystem" variants
Thomas.Hauth at kit.edu
Sun Jan 25 07:40:32 PST 2015
Dear clang Developers,
this is a follow-up on a bug report , as I encountered the same
problem. The ccc-analyzer script used during the scan-build static
analysis process is not properly forwarding options to the underlying
compiler. The '-isystem' flag, which marks an include directory to
contain system headers, is only forwarded if a white space is present
between "-isystem" and <path>. While both clang rev 226467 and gcc 4.8.3
support both ("-isystem <path>" and "-isystem<path>"), the ccc-analyzer
can only handle version with a white space.
There is no clear documentation whether "-isystem" can contain a
whitespace, but the gcc documentation states, that "-isystem" can be
used in place of "-I"  which suggest to use it without a whitespace.
Clang's user manual has one example on using "-isystem", but with a
white space . I added an example makefile with instructions how to
reproduce this problem to the above bug report.
I attached a patch which enables ccc-analyzer to accept and forward both
the "-isystem <path>" and "-isystem<path>" variant.
The attached patch was created against 227046.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 585 bytes
Desc: not available
More information about the cfe-commits