[v3] Export std::_List_node_base for non-PIC code

Submitted by Rainer Orth on April 5, 2012, 9:15 a.m.


Message ID yddty0yo7yb.fsf@manam.CeBiTec.Uni-Bielefeld.DE
State New
Headers show

Commit Message

Rainer Orth April 5, 2012, 9:15 a.m.
As discussed in PR libstdc++/52689, no longer exporting
std::_List_node_base for non-PIC code breaks linking go1 on Solaris with
static libstdc++:

Undefined                       first referenced
 symbol                             in file
_ZNSt15_List_node_base4swapERS_S0_  /vol/gcc/lib/libppl_c.a(ppl_c_Pointset_Powerset_C_Polyhedron.o)
_ZNSt15_List_node_base4hookEPS_     /vol/gcc/lib/libppl_c.a(ppl_c_Polyhedron.o)
_ZNSt15_List_node_base6unhookEv     /vol/gcc/lib/libppl_c.a(ppl_c_Pointset_Powerset_C_Polyhedron.o)
_ZNSt15_List_node_base8transferEPS_S0_ /vol/gcc/lib/libppl_c.a(ppl_c_Pointset_Powerset_C_Polyhedron.o)
ld: fatal: symbol referencing errors. No output written to go1

The following patch fixes this, bootstrapped without regressions on
i386-pc-solaris2.11, approved by Benjamin in the PR, installed on


2012-04-05  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>

	Partially revert:
	2012-03-28  Benjamin Kosnik  <bkoz@redhat.com>

	PR libstdc++/52689
	* src/c++98/compatibility-list.cc: Same.

Patch hide | download patch | download mbox

# HG changeset patch
# Parent 5e498daa5c157ffd17681f8d800f6866eb837cf6
Export std::_List_node_base for non-PIC code

diff --git a/libstdc++-v3/src/c++98/compatibility-list.cc b/libstdc++-v3/src/c++98/compatibility-list.cc
--- a/libstdc++-v3/src/c++98/compatibility-list.cc
+++ b/libstdc++-v3/src/c++98/compatibility-list.cc
@@ -24,8 +24,6 @@ 
 #include <bits/move.h>
-#ifdef PIC
 } // namespace std