<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 - Undefined symbols when using -static-libstdc++"
href="https://bugs.llvm.org/show_bug.cgi?id=32360">32360</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Undefined symbols when using -static-libstdc++
</td>
</tr>
<tr>
<th>Product</th>
<td>lld
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</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>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>ELF
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>wielkiegie@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=18141" name="attach_18141" title="lld errors with -Wl,-error-limit=0">attachment 18141</a> <a href="attachment.cgi?id=18141&action=edit" title="lld errors with -Wl,-error-limit=0">[details]</a></span>
lld errors with -Wl,-error-limit=0
This is a follow-up of <a class="bz_bug_link
bz_status_ASSIGNED "
title="ASSIGNED - Inconsistent init_array section type when using -static-libstdc++"
href="show_bug.cgi?id=32307">bug 32307</a>.
When building using gcc-5.2 and -static-libstdc++ option:
echo -e '#include<iostream>\nint main() { return 0; }' | g++ -xc++ -
-static-libstdc++
there are multiple undefined symbol errors returned. Some of them:
ld: error: ../../../../../gcc-5.2.0/libstdc++-v3/src/c++98/ios_init.cc:181:
undefined symbol '__gnu_cxx::stdio_filebuf<char, std::char_traits<char>
<span class="quote">>::stdio_filebuf(_IO_FILE*, std::_Ios_Openmode, unsigned long)'</span >
ld: error: ../../../../gcc-5.2.0/libstdc++-v3/src/c++98/compatibility.cc:67:
undefined symbol 'std::istream::sentry::sentry(std::istream&, bool)'
ld: error:
/tmp/gcc_sg221270/gcc-build/x86_64-redhat-linux-gnu/libstdc++-v3/include/bits/locale_facets_nonio.h:1283:
undefined symbol 'std::basic_string<char, std::char_traits<char>,
std::allocator<char> >::basic_string(char const*, std::allocator<char> const&)'
All the errors are in the attached file.
Here is the link to the repro.tar.gz file (file too large to attach):
<a href="https://drive.google.com/open?id=0B97COcsEYuQgUU04cXAtYzdxWU0">https://drive.google.com/open?id=0B97COcsEYuQgUU04cXAtYzdxWU0</a></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>