This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH, libstdc++]: Fix static linking failure on alphaev68-pc-linux-gnu
- From: Uros Bizjak <ubizjak at gmail dot com>
- To: gcc-patches at gcc dot gnu dot org
- Cc: libstdc++ at gcc dot gnu dot org
- Date: Wed, 4 Apr 2012 19:33:52 +0200
- Subject: [PATCH, libstdc++]: Fix static linking failure on alphaev68-pc-linux-gnu
Hello!
The fix for PR52689 caused following testsuite failure on
alphaev68-pc-linux-gnu:
Running target unix
FAIL: libmudflap.c++/pass41-frag.cxx (-static) (test for excess errors)
WARNING: libmudflap.c++/pass41-frag.cxx (-static) compilation failed
to produce executable
>From the testsuite log:
/home/uros/gcc-build/alphaev68-unknown-linux-gnu/libstdc++-v3/src/.libs/libstdc++.a(locale.o):
In function `std::locale::id::_M_id() const':^M
/home/uros/gcc-build/alphaev68-unknown-linux-gnu/libstdc++-v3/src/c++98/../../../../../gcc-svn/trunk/libstdc++-v3/src/c++98/locale.cc:423:
undefined reference to `std::num_get<char, std::istreambuf_iterator<char,
std::char_traits<char> > >::id'^M
/home/uros/gcc-build/alphaev68-unknown-linux-gnu/libstdc++-v3/src/c++98/../../../../../gcc-svn/trunk/libstdc++-v3/src/c++98/locale.cc:424:
undefined reference to `std::num_put<char, std::ostreambuf_iterator<char,
std::char_traits<char> > >::id'^M
/home/uros/gcc-build/alphaev68-unknown-linux-gnu/libstdc++-v3/src/c++98/../../../../../gcc-svn/trunk/libstdc++-v3/src/c++98/locale.cc:425:
undefined reference to `std::money_get<char, std::istreambuf_iterator<char,
std::char_traits<char> > >::id'^M
/home/uros/gcc-build/alphaev68-unknown-linux-gnu/libstdc++-v3/src/c++98/../../../../../gcc-svn/trunk/libstdc++-v3/src/c++98/locale.cc:426:
undefined reference to `std::money_put<char, std::ostreambuf_iterator<char,
std::char_traits<char> > >::id'^M
/home/uros/gcc-build/alphaev68-unknown-linux-gnu/libstdc++-v3/src/c++98/../../../../../gcc-svn/trunk/libstdc++-v3/src/c++98/locale.cc:428:
undefined reference to `std::num_get<wchar_t, std::istreambuf_iterator<wchar_t,
std::char_traits<wchar_t> > >::id'^M
/home/uros/gcc-build/alphaev68-unknown-linux-gnu/libstdc++-v3/src/c++98/../../../../../gcc-svn/trunk/libstdc++-v3/src/c++98/locale.cc:429:
undefined reference to `std::num_put<wchar_t, std::ostreambuf_iterator<wchar_t,
std::char_traits<wchar_t> > >::id'^M
/home/uros/gcc-build/alphaev68-unknown-linux-gnu/libstdc++-v3/src/c++98/../../../../../gcc-svn/trunk/libstdc++-v3/src/c++98/locale.cc:430:
undefined reference to `std::money_get<wchar_t,
std::istreambuf_iterator<wchar_t, std::char_traits<wchar_t> > >::id'^M
This happens in #ifdef _GLIBCXX_LONG_DOUBLE_COMPAT protected code.
Following partial revert fixes the failure:
2012-04-04 Uros Bizjak <ubizjak@gmail.com>
Partially revert:
2012-03-28 Benjamin Kosnik <bkoz@redhat.com>
PR libstdc++/52689
* src/c++98/compatibility-ldbl.cc: Guard with PIC
Tested on alphaev68-pc-linux-gnu, approved in the PR audit trail by
Benjamin, committed to SVN.
Uros.
Index: src/c++98/compatibility-ldbl.cc
===================================================================
--- src/c++98/compatibility-ldbl.cc (revision 186092)
+++ src/c++98/compatibility-ldbl.cc (working copy)
@@ -27,8 +27,6 @@
#include <cmath>
#include <tr1/functional>
-#ifdef PIC
-
#ifdef _GLIBCXX_LONG_DOUBLE_COMPAT
#ifdef __LONG_DOUBLE_128__
@@ -80,5 +78,3 @@
__attribute__((alias ("_ZNKSt3tr14hashIeEclEe")));
#endif
-
-#endif