<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<p><br>
</p>
<div class="moz-cite-prefix">Le 06/10/2019 à 02:59, Thorsten Glaser
a écrit :<br>
</div>
<blockquote type="cite"
cite="mid:alpine.DEB.2.21.1910060256100.24225@tglase-nb.lan.tarent.de">
<pre class="moz-quote-pre" wrap="">On Sun, 6 Oct 2019, Thorsten Glaser wrote:
</pre>
<blockquote type="cite">
<pre class="moz-quote-pre" wrap="">… which is caused by:
cc1: error: unrecognized argument to '-flto=' option: 'thin'
Somehow, the build system applies -flto=thin to the host compiler,
and GCC doesn’t support this flag.
</pre>
</blockquote>
<pre class="moz-quote-pre" wrap="">
This is but the first error. When I comment out the LTO line
in d/rules the build continues for hours but then:
[…]
clang-8: note: diagnostic msg:
********************
PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang-8: note: diagnostic msg: /tmp/ManagedStatic-201574.cpp
clang-8: note: diagnostic msg: /tmp/ManagedStatic-201574.sh
clang-8: note: diagnostic msg:
********************
make[8]: *** [lib/Support/CMakeFiles/LLVMSupport.dir/build.make:794: lib/Support/CMakeFiles/LLVMSupport.dir/ManagedStatic.cpp.o] Error 70
</pre>
<br>
</blockquote>
<p>Interesting, this isn't the same error as in the CI.<br>
</p>
<p><a class="moz-txt-link-freetext" href="https://buildd.debian.org/status/fetch.php?pkg=llvm-toolchain-8&arch=x32&ver=1%3A8.0.1-3&stamp=1565281145&raw=0">https://buildd.debian.org/status/fetch.php?pkg=llvm-toolchain-8&arch=x32&ver=1%3A8.0.1-3&stamp=1565281145&raw=0</a></p>
<p>where the error is:<br>
</p>
<pre> /<<PKGBUILDDIR>>/build-llvm/./bin/clang -fuse-ld=gold -fPIC -Wno-unused-command-line-argument -Wno-unknown-warning-option -fuse-ld=gold -fPIC -Wno-unused-command-line-argument -Wno-unknown-warning-option -Wl,--build-id CMakeFiles/cmTC_1e221.dir/testCCompiler.c.o -o cmTC_1e221
/usr/bin/ld.gold: error: cannot open crt1.o: No such file or directory
/usr/bin/ld.gold: error: cannot open crti.o: No such file or directory
/usr/bin/ld.gold: error: cannot open crtbegin.o: No such file or directory
/usr/bin/ld.gold: error: cannot open crtend.o: No such file or directory
/usr/bin/ld.gold: error: cannot open crtn.o: No such file or directory
/usr/bin/ld.gold: error: cannot find -lgcc
/usr/bin/ld.gold: error: cannot find -lgcc_s
/usr/bin/ld.gold: error: cannot find -lgcc
/usr/bin/ld.gold: error: cannot find -lgcc_s
clang-8: error: linker command failed with exit code 1 (use -v to see invocation)
Which should be easy to fix (I guess it is a missing path in <code>clang/lib/Driver/ToolChains/Gnu.c )
I don't have the bandwidth in the next month to manage non official arch but I will be happy to take a patch or to guide.
About the lto issue, it is fixed in the branch 9 (I am focussing my time on this branch):
<a class="moz-txt-link-freetext" href="https://salsa.debian.org/pkg-llvm-team/llvm-toolchain/commit/2a58c5d841443533b00997207827b2576855a6a7">https://salsa.debian.org/pkg-llvm-team/llvm-toolchain/commit/2a58c5d841443533b00997207827b2576855a6a7</a>
<a class="moz-txt-link-freetext" href="https://salsa.debian.org/pkg-llvm-team/llvm-toolchain/commit/c6417dbaeffc915fca275d4aa7038cdf7f3e17b7">https://salsa.debian.org/pkg-llvm-team/llvm-toolchain/commit/c6417dbaeffc915fca275d4aa7038cdf7f3e17b7</a>
Cheers,
Sylvestre
</code></pre>
</body>
</html>