HP-UX ld segfaults during build of GCC 3.4.0

From: Baby Peanut (baby_p_nut2_at_yahoo.com)
Date: 05/21/04


Date: 21 May 2004 12:51:24 -0700


$ uname -srv
HP-UX B.11.11 U
$ type ar
ar is /usr/bin/ar
(All copies of GNU binutils ar have been renamed to ar-do-not-use;
using GNU ar led to the same segmention violation in ld. Some old
post suggested that was the cause but I doubt it now.)

$ swlist | grep -i GOLD
  GOLDAPPS11i B.11.11.0312.4 Gold Applications Patches for
HP-UX 11i v1, December 2003
  GOLDBASE11i B.11.11.0312.4 Gold Base Patches for HP-UX 11i
v1, December 2003

Is this a known issue? Is there a patch for ld?

I tried bumping up the data segment and then the stack segment but
with this I still get the segmentation fault in /usr/bin/ld.

$ ulimit -a
core file size (blocks, -c) 2097151
data seg size (kbytes, -d) 921600
file size (blocks, -f) unlimited
max memory size (kbytes, -m) unlimited
open files (-n) 60
pipe size (512 bytes, -p) 16
stack size (kbytes, -s) 31744
cpu time (seconds, -t) unlimited
max user processes (-u) 76
virtual memory (kbytes, -v) unlimited

$ what /usr/bin/ld
/usr/bin/ld:
        HP aC++ B3910B A.03.25 Classic Iostream Library
        HP aC++ B3910B A.03.25 Language Support Library
        ld_msgs.cat: $Revision: 1.85 $
        92453-07 linker command s800.sgs ld PA64 B.11.18 REL 000922

/opt/gnudev/src/gcc-3.4.0-obj/gcc/xgcc -shared-libgcc
-B/opt/gnudev/src/gcc-3.4.0-obj/gcc/ -nostdinc++
-L/opt/gnudev/src/gcc-3.4.0-obj/hppa2.0w-hp-hpux11.11/libstdc++-v3/src
-L/opt/gnudev/src/gcc-3.4.0-obj/hppa2.0w-hp-hpux11.11/libstdc++-v3/src/.libs
-B/opt/gnudev/hppa2.0w-hp-hpux11.11/bin/
-B/opt/gnudev/hppa2.0w-hp-hpux11.11/lib/ -isystem
/opt/gnudev/hppa2.0w-hp-hpux11.11/include -isystem
/opt/gnudev/hppa2.0w-hp-hpux11.11/sys-include -shared -nostdlib -fPIC
-Wl,+h -Wl,libstdc++.sl.6 -Wl,+b -Wl,/opt/gnudev/lib -o
.libs/libstdc++.sl.6.0 .libs/allocator.o .libs/codecvt.o
.libs/complex_io.o .libs/ctype.o .libs/debug.o .libs/debug_list.o
.libs/functexcept.o .libs/globals_locale.o .libs/globals_io.o
.libs/ios.o .libs/ios_failure.o .libs/ios_init.o .libs/ios_locale.o
.libs/limits.o .libs/list.o .libs/locale.o .libs/locale_init.o
.libs/locale_facets.o .libs/localename.o .libs/stdexcept.o
.libs/strstream.o .libs/tree.o .libs/allocator-inst.o
.libs/concept-inst.o .libs/fstream-inst.o .libs/ext-inst.o
.libs/io-inst.o .libs/istream-inst.o .libs/locale-inst.o
.libs/locale-misc-inst.o .libs/misc-inst.o .libs/ostream-inst.o
.libs/sstream-inst.o .libs/streambuf-inst.o .libs/string-inst.o
.libs/valarray-inst.o .libs/wlocale-inst.o .libs/wstring-inst.o
.libs/atomicity.o .libs/codecvt_members.o .libs/collate_members.o
.libs/ctype_members.o .libs/messages_members.o
.libs/monetary_members.o .libs/numeric_members.o .libs/time_members.o
.libs/basic_file.o .libs/c++locale.o
.libs/libstdc++.lax/libmath.a/stubs.o
.libs/libstdc++.lax/libmath.a/signbit.o
.libs/libstdc++.lax/libmath.a/signbitf.o
.libs/libstdc++.lax/libsupc++convenience.a/del_op.o
.libs/libstdc++.lax/libsupc++convenience.a/del_opnt.o
.libs/libstdc++.lax/libsupc++convenience.a/del_opv.o
.libs/libstdc++.lax/libsupc++convenience.a/del_opvnt.o
.libs/libstdc++.lax/libsupc++convenience.a/eh_alloc.o
.libs/libstdc++.lax/libsupc++convenience.a/eh_aux_runtime.o
.libs/libstdc++.lax/libsupc++convenience.a/eh_catch.o
.libs/libstdc++.lax/libsupc++convenience.a/eh_exception.o
.libs/libstdc++.lax/libsupc++convenience.a/eh_globals.o
.libs/libstdc++.lax/libsupc++convenience.a/eh_personality.o
.libs/libstdc++.lax/libsupc++convenience.a/eh_term_handler.o
.libs/libstdc++.lax/libsupc++convenience.a/eh_terminate.o
.libs/libstdc++.lax/libsupc++convenience.a/eh_throw.o
.libs/libstdc++.lax/libsupc++convenience.a/eh_type.o
.libs/libstdc++.lax/libsupc++convenience.a/eh_unex_handler.o
.libs/libstdc++.lax/libsupc++convenience.a/guard.o
.libs/libstdc++.lax/libsupc++convenience.a/new_handler.o
.libs/libstdc++.lax/libsupc++convenience.a/new_op.o
.libs/libstdc++.lax/libsupc++convenience.a/new_opnt.o
.libs/libstdc++.lax/libsupc++convenience.a/new_opv.o
.libs/libstdc++.lax/libsupc++convenience.a/new_opvnt.o
.libs/libstdc++.lax/libsupc++convenience.a/pure.o
.libs/libstdc++.lax/libsupc++convenience.a/tinfo.o
.libs/libstdc++.lax/libsupc++convenience.a/tinfo2.o
.libs/libstdc++.lax/libsupc++convenience.a/vec.o
.libs/libstdc++.lax/libsupc++convenience.a/vterminate.o
.libs/libstdc++.lax/libsupc++convenience.a/cp-demangle.o
-L/opt/gnudev/src/gcc-3.4.0-obj/hppa2.0w-hp-hpux11.11/libstdc++-v3/src
-L/opt/gnudev/src/gcc-3.4.0-obj/hppa2.0w-hp-hpux11.11/libstdc++-v3/src/.libs
-lm ../libmath/.libs/libmath.a -lm
../libsupc++/.libs/libsupc++convenience.a -lm
-L/opt/gnudev/src/gcc-3.4.0-obj/gcc
-L/opt/gnudev/hppa2.0w-hp-hpux11.11/bin
-L/opt/gnudev/lib/gcc/hppa2.0w-hp-hpux11.11/3.4.0 -L/usr/ccs/bin
-L/usr/ccs/lib -L/opt/gnudev/lib -lgcc_s -lgcc_s -lm -lgcc_s -lgcc_s
-lc
collect2: ld terminated with signal 11 [Segmentation fault], core
dumped

$ find . -name core
./hppa2.0w-hp-hpux11.11/libstdc++-v3/src/core
$ cd hppa2.0w-hp-hpux11.11/libstdc++-v3/src
$ gdb /usr/bin/ld
GNU gdb 4.18
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for
details.
This GDB was configured as "hppa2.0w-hp-hpux11.00"...
(no debugging symbols found)...
(gdb) core core
Core was generated by `ld32'.
Program terminated with signal 11, Segmentation fault.
Unable to find __dld_flags symbol in object file.

#0 0x185b4 in ?? ()
(gdb) where
#0 0x185b4 in ?? ()
#1 0x185b8 in ?? ()
Cannot access memory at address 0x300a0212.



Relevant Pages

  • Re: jdk 1.3.1 in FreeBSD
    ... >And when I use gdb to trace the core file, ... ># gdb java java.core ... Segmentation fault. ...
    (freebsd-questions)
  • RE: jdk 1.3.1 in FreeBSD
    ... And when I use gdb to trace the core file, it can't recognize the file format: ... # gdb java java.core ... Segmentation fault. ...
    (freebsd-questions)
  • Re: sfxload issues.
    ... Red Hat Linux release 7.0 ... > Segmentation fault (core dumped) ... > GDB is free software, covered by the GNU General Public License, and you ...
    (Vuln-Dev)
  • Re: kgdb segfaulting
    ... GDB is free software, covered by the GNU General Public License, and you are ... There is absolutely no warranty for GDB. ... Segmentation fault. ...
    (freebsd-current)
  • [UNIX] Progress Database Local Buffer Overflow
    ... # gdb /usr/dlc/bin/_mpros core ... Segmentation fault. ... Reading symbols from /lib/libm.so.6...done. ... There is absolutely no warranty for GDB. ...
    (Securiteam)