This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
-lpthread -lstdc++ crashes on IRIX 6.5
- From: "Peter O'Gorman" <pogma at thewrittenword dot com>
- To: gcc-help at gcc dot gnu dot org
- Cc: ro at CeBiTec dot Uni-Bielefeld dot DE
- Date: Mon, 21 Feb 2011 12:10:36 -0600
- Subject: -lpthread -lstdc++ crashes on IRIX 6.5
Hi,
We're currently using gcc-4.4.
On IRIX 6.5, we get crashes if -lpthread is ordered before
-lstdc++ (warnings about "not used for resolving any symbol" removed
below):
% echo 'int main() {}' >a.cpp
% g++ a.cpp -lpthread; ./a.out; echo $?
zsh: segmentation fault (core dumped) ./a.out
139
% g++ a.cpp -pthread; ./a.out; echo $?
0
% g++ a.cpp -lstdc++ -lpthread; ./a.out; echo $?
0
With gcc-4.2.x we had a similar issue, but on Tru64, that seems to be
fixed in 4.4.5. We have not tried trunk yet, is the problem already
fixed there?
We're looking at reordering -lpthread to come after -lstdc++ by patching
cp/g++spec.c to fix this, but perhaps that is the wrong approach?
Thanks for any help,
Peter
--
Peter O'Gorman
pogma@thewrittenword.com