<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Fails to build with gcc because the new compiler's internal headers are used with the bootstrap compiler"
href="https://bugs.llvm.org/show_bug.cgi?id=42453">42453</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Fails to build with gcc because the new compiler's internal headers are used with the bootstrap compiler
</td>
</tr>
<tr>
<th>Product</th>
<td>new-bugs
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>enhancement
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>new bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>bero@lindev.ch
</td>
</tr>
<tr>
<th>CC</th>
<td>htmldeveloper@gmail.com, llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>Trying to build current LLVM trunk with all subprojects enabled with gcc 9.1
results in
/usr/bin/g++ -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS
-D__STDC_LIMIT_MACROS -Itools/clang/lib/Tooling/Inclusions
-I/builddir/build/BUILD/llvm-9.0.0-20190629/clang/lib/Tooling/Inclusions
-I/builddir/build/BUILD/llvm-9.0.0-20190629/clang/include -Itools/clang/include
-I/usr/include/libxml2 -Iinclude
-I/builddir/build/BUILD/llvm-9.0.0-20190629/llvm/include
-I/builddir/build/BUILD/llvm-9.0.0-20190629/clang/lib/Headers -Os
-fomit-frame-pointer -pipe -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2
-fstack-protector-strong --param=ssp-buffer-size=4 -march=rv64imafdc
-mabi=lp64d -O3 -D_LARGEFILE_SOURCE=1 -D_LARGEFILE64_SOURCE=1
-D_FILE_OFFSET_BITS=64 -fuse-ld=bfd -fPIC -fvisibility-inlines-hidden
-Werror=date-time -std=c++1y -Wall -Wextra -Wno-unused-parameter
-Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic
-Wno-long-long -Wimplicit-fallthrough -Wno-maybe-uninitialized
-Wno-class-memaccess -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wno-comment
-fdiagnostics-color -ffunction-sections -fdata-sections -fno-common
-Woverloaded-virtual -fno-strict-aliasing -Os -fomit-frame-pointer -pipe
-Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -fstack-protector-strong
--param=ssp-buffer-size=4 -march=rv64imafdc -mabi=lp64d -O3
-D_LARGEFILE_SOURCE=1 -D_LARGEFILE64_SOURCE=1 -D_FILE_OFFSET_BITS=64
-fuse-ld=bfd -MD -MT
tools/clang/lib/Tooling/Inclusions/CMakeFiles/obj.clangToolingInclusions.dir/IncludeStyle.cpp.o
-MF
tools/clang/lib/Tooling/Inclusions/CMakeFiles/obj.clangToolingInclusions.dir/IncludeStyle.cpp.o.d
-o
tools/clang/lib/Tooling/Inclusions/CMakeFiles/obj.clangToolingInclusions.dir/IncludeStyle.cpp.o
-c
/builddir/build/BUILD/llvm-9.0.0-20190629/clang/lib/Tooling/Inclusions/IncludeStyle.cpp
In file included from /usr/include/c++/9.1.0/bits/cxxabi_init_exception.h:38,
from /usr/include/c++/9.1.0/bits/exception_ptr.h:38,
from /usr/include/c++/9.1.0/exception:143,
from /usr/include/c++/9.1.0/new:40,
from
/builddir/build/BUILD/llvm-9.0.0-20190629/llvm/include/llvm/Support/Compiler.h:19,
from
/builddir/build/BUILD/llvm-9.0.0-20190629/llvm/include/llvm/ADT/Optional.h:19,
from
/builddir/build/BUILD/llvm-9.0.0-20190629/llvm/include/llvm/Support/YAMLTraits.h:12,
from
/builddir/build/BUILD/llvm-9.0.0-20190629/clang/include/clang/Tooling/Inclusions/IncludeStyle.h:12,
from
/builddir/build/BUILD/llvm-9.0.0-20190629/clang/lib/Tooling/Inclusions/IncludeStyle.cpp:9:
/builddir/build/BUILD/llvm-9.0.0-20190629/clang/lib/Headers/stddef.h:22:19:
error: missing binary operator before token "("
22 | #if !__has_feature(modules)
| ^
Looks like the problem is that the internal headers for the compiler being
built (clang/lib/headers/stddef.h inside the source tree) are being used
instead of gcc's stddef.h</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>