Beispiel #1
0
    By <a href="mailto:sylvestre@debian.org">Sylvestre Ledru</a> (<a href="http://www.debian.org/">Debian</a>, <a href="http://www.irill.org/">IRILL</a>). February 28th 2012 (clang 3.0),  June 23th 2012 (clang 3.1), January 28th 2013 (clang 3.2), July 14th 2013 (clang 3.3), January 10th 2014 (clang 3.4), June 6th 2014 (clang 3.4.2), September 7th 2014 (clang 3.5.0), March 2th 2015 (3.6.0)<br />


<h1>Presentation</h1>
This document presents the result of the rebuild of the Debian archive (the distribution) with <a href="http://packages.qa.debian.org/c/clang.html">clang</a>, a new C/C++ compiler.<br />
<br />
clang is now ready to build software for production (either for C, C++ or Objective-C). This compiler is providing many more warnings and interesting errors than the gcc suite while not carrying the same legacy as gcc.<br />
This rebuild has several goals. The first one is to prove (or not) that clang is a viable alternative. Second, building a software with different compilers improves the overall quality of code by providing different checks and alerts.

<br />
<h1>Rebuild results</h1>

The detailed list of errors:<br />
<?

    resultClangDisplay($currentVersion, false);
?>
<br />
Errors can be caused by several reasons:<br />
<ul>
<li>Refused declarations. See <a href="/status.php?version=<?php 
echo $currentVersion;
?>
&key=FUNCTION_RETURNS_VALUE">example 1</a>, <a href="/status.php?version=<?php 
echo $currentVersion;
?>
&key=MAIN_RETURNS_INT">example 2</a>, etc. </li>
<li>Different warnings options list in <i>-Wall</i> or <i>-Wextra</i> (which will fail with -Werror). See <a href="/status.php?version=<?php 
echo $currentVersion;
?>
&key=TAUTOLOGICAL-COMPARE">example 1</a>, <a href="status.php?version=<?php 
Beispiel #2
0
<br />
clang is now stable and good enough to rebuild most of the packages in the Debian archive.<br />
<br />
<br />
<h1>Rebuild</h1>
    The rebuild itself has been done on a cluster called Grid 5000.<br />
<br />
Each packages in the Debian archive has been rebuild with the chroot descrived further. <br />
     For each packages failing to build from the source with clang, the package has been rebuild with a "normal" Debian sid chroot. If working, we considered that it was due to a clang bug. Otherwise, the package is not listed in this list.<br />
<br />
<br />
<h1>Bug results</h1>

The detailled list of errors:<br />
<?
    resultClangDisplay($currentVersion);
?>
<br />
The most common errors is a difference in the symbol list generated with gcc/g++ and clang.<br />
Other errors can be caused by several reasons:<br />
<ul>
<li>mangling issues</li>
<li>implicit declarations</li>
<li>different warnings options list in <i>-Wall</i> or <i>-Wextra</i> (which will fail with -Werror)</li>
<li>define qui serait existent mais pas trouvé (donc il met le symbol en implicit et remplace pas le define => verifier)</li>
</ul>
<br />
<br />
Some kind of errors are listed with 0 failure. Those are issues which occured with clang 2.9 which has been fixed by upstream with the version 3.0.<br />
<br />
<br />
Beispiel #3
0
<img src="irill.png" align="right" />
<h1 id="title"><a href="/">Debian Package rebuild</a></h1>
<h2 id="subtitle">Rebuild of the Debian archive with clang</h2>
<div id="body">

<? 
    $totalDebian=$clangVersions[$versionGET];
    if (!isset($keyGET) || $keyGET == "") {
?>
<div align="center">clang <?php 
echo $versionGET;
?>
</div><br />

<?
    resultClangDisplay($versionGET);
 } 
else 
{


?>
<div align="center">
    <i>"<?php 
echo $keyDSC;
?>
"</i> build failure(s)<br />clang <?php 
echo $versionGET;
?>
</div>
<div align="right">    <a href="status.php">Return to the list</a></div>