<html>
<head>
<base href="https://bugs.documentfoundation.org/">
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - use the CLang++ static analyser to find bugs"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=39596#c33">Comment # 33</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - use the CLang++ static analyser to find bugs"
href="https://bugs.documentfoundation.org/show_bug.cgi?id=39596">bug 39596</a>
from <span class="vcard"><a class="email" href="mailto:hoes.maarten@gmail.com" title="Maarten Hoes <hoes.maarten@gmail.com>"> <span class="fn">Maarten Hoes</span></a>
</span></b>
<pre>One of the problems with doing this, as far as I can see, is this:
The developers of LibreOffice seem to be interested only/primarily in analyzing
the core LibreOffice codebase, and not in the many dependencies/pre-requisites
of that codebase (and understandably so). Unfortunately, the tool that does the
actual analysis (scan-build) will and can only (largely due to the way the
analyzer is interposing on the compiler) analyze *all* the code that gets build
when you run 'make'. There is no way to tell 'scan-build' that you specifically
want to include/exclude parts of the source(-tree) that gets build when you run
'make'. There's an enhancement request to add this functionality over at llvm
bugzilla [1], but so far it has not been added.
So when you run 'autogen.sh/configure' with '--without-system-libs
--without-system-headers', which would be the easiest way to ensure you get all
the right dependencies/pre-requisites in their correct respective versions
(included/pulled-in in the LibreOffice source tree), not only the LibreOffice
codebase gets analyzed, but all the dependencies/pre-requisites as well, as all
of these will be build during 'make'.
Which means that you are pretty much forced to use 'autogen.sh/configure' with
'--with-system-libs --with-system-headers', as using the distribution provided
binaries excludes them from being build during 'make' and therefore excluded
from analysis. But this requires you to install all the
dependencies/pre-requisites system-wide, and not all (or perhaps even none)
Linux distributions offer the needed packages, or not in the right versions.
Also, every time the LibreOffice source needs an updated version of a package
or a new package, you're going to need a way to determine this new
package/version in an automated way, and then install it (assuming the
distribution has a pre-build package available in the right version to begin
with).
[1]
<a href="https://bugs.llvm.org//show_bug.cgi?id=22594">https://bugs.llvm.org//show_bug.cgi?id=22594</a></pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>