From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by listman.redhat.com (Postfix) with ESMTP id C527642D67 for ; Fri, 18 Oct 2002 17:29:50 -0400 (EDT) Received: (from mail@localhost) by int-mx1.corp.redhat.com (8.11.6/8.11.6) id g9ILTo518296 for axp-list@listman.redhat.com; Fri, 18 Oct 2002 17:29:50 -0400 Received: from mx1.redhat.com (mx1.redhat.com [172.16.48.31]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with SMTP id g9ILTof18292 for ; Fri, 18 Oct 2002 17:29:50 -0400 Received: from Marvin.DL8BCU.ampr.org (root@pD9E57370.dip.t-dialin.net [217.229.115.112]) by mx1.redhat.com (8.11.6/8.11.6) with SMTP id g9IL8nw29659 for ; Fri, 18 Oct 2002 17:08:49 -0400 Received: from dl8bcu.de (th@localhost [127.0.0.1]) by Marvin.DL8BCU.ampr.org (8.12.1/8.12.1) with ESMTP id g9ILTlCl009114 for ; Fri, 18 Oct 2002 21:29:47 GMT Received: (from th@localhost) by dl8bcu.de (8.12.1/8.12.1/Submit) id g9ILTkcp009113 for axp-list@redhat.com; Fri, 18 Oct 2002 21:29:46 GMT X-Authentication-Warning: Marvin.borg.net: th set sender to dl8bcu@dl8bcu.de using -f Date: Fri, 18 Oct 2002 21:29:46 +0000 From: Thorsten Kranzkowski To: axp-list mailing list Subject: strange linker error Message-ID: <20021018212946.A9104@Marvin.DL8BCU.ampr.org> Mail-Followup-To: axp-list mailing list Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0.1i X-Loop: axp-list@redhat.com Sender: axp-list-admin@redhat.com Errors-To: axp-list-admin@redhat.com X-BeenThere: axp-list@redhat.com X-Mailman-Version: 2.0.1 Precedence: bulk Reply-To: axp-list@redhat.com X-Reply-To: dl8bcu@dl8bcu.de List-Help: List-Post: List-Subscribe: , List-Id: Linux and Red Hat on Alpha processors List-Unsubscribe: , List-Archive: Hello! I'm trying to compile mozilla on my alpha, however I get this strange linker error: rm -f libxpcom.so c++ -I/usr/X11R6/include -fno-rtti -fno-exceptions -Wall -Wconversion -Wpointer-arith -Wbad-function-cast -Wcast-align -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy -pedantic -Wno-long-long -mieee -fshort-wchar -pthread -pipe -DDEBUG -D_DEBUG -DDEBUG_th -DTRACING -g -fno-inline -fPIC -shared -Wl,-h -Wl,libxpcom.so -o libxpcom.so nsXPComInit.o -Wl,--whole-archive ../../dist/lib/libxpcomds_s.a ../../dist/lib/libxpcomio_s.a ../../dist/lib/libxpcomcomponents_s.a ../../dist/lib/libxpcomthreads_s.a ../../dist/lib/libxpcomproxy_s.a ../../dist/lib/libxpcombase_s.a ../../dist/lib/libxptcall.a ../../dist/lib/libxptinfo.a ../../dist/lib/libxpt.a ../../dist/lib/libxptcmd.a ../../dist/lib/libmozreg_s.a ../../dist/lib/libstring_s.a ../../dist/lib/libstring_obsolete_s.a ../../dist/lib/libxpcomglue_s.a -Wl,--no-whole-archive -liberty -L/usr/src/mozilla/dist/lib -lplds4 -lplc4 -lnspr4 -lpthread -ldl -ldl -lm /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../../alphaev6-unknown-linux-gnu/bin/ld: /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../libiberty.a(cplus-dem.o): gp-relative relocation against dynamic symbol libiberty_demanglers /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../../alphaev6-unknown-linux-gnu/bin/ld: /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../libiberty.a(cplus-dem.o): gp-relative relocation against dynamic symbol libiberty_demanglers /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../../alphaev6-unknown-linux-gnu/bin/ld: /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../libiberty.a(cplus-dem.o): gp-relative relocation against dynamic symbol current_demangling_style /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../../alphaev6-unknown-linux-gnu/bin/ld: /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../libiberty.a(cplus-dem.o): gp-relative relocation against dynamic symbol current_demangling_style /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../../alphaev6-unknown-linux-gnu/bin/ld: /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../libiberty.a(cplus-dem.o): gp-relative relocation against dynamic symbol libiberty_demanglers /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../../alphaev6-unknown-linux-gnu/bin/ld: /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../libiberty.a(cplus-dem.o): gp-relative relocation against dynamic symbol libiberty_demanglers /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../../alphaev6-unknown-linux-gnu/bin/ld: /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../libiberty.a(cplus-dem.o): gp-relative relocation against dynamic symbol current_demangling_style /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../../alphaev6-unknown-linux-gnu/bin/ld: /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../libiberty.a(cplus-dem.o): gp-relative relocation against dynamic symbol current_demangling_style /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../../alphaev6-unknown-linux-gnu/bin/ld: /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/../../../libiberty.a(cplus-dem.o): gp-relative relocation against dynamic symbol current_demangling_style collect2: ld returned 1 exit status make[3]: *** [libxpcom.so] Error 1 make[3]: Leaving directory `/usr/src/mozilla/xpcom/build' A quick look at cplus_dem.o (built as part of gcc) reveals that there are indeed gp-relative relocations inside: [...] SYMBOL TABLE: [...] 0000000000000000 g O .sdata 0000000000000004 current_demangling_style [...] 0000000000000768 g O .rodata 0000000000000108 libiberty_demanglers [...] 0000000000000970 : 970: 00 00 bb 27 ldah gp,0(t12) 970: GPDISP .text+0x4 974: 00 00 bd 23 lda gp,0(gp) 978: 00 00 3d 24 ldah t0,0(gp) 978: GPRELHIGH libiberty_demanglers 97c: 00 00 61 20 lda t2,0(t0) 97c: GPRELLOW libiberty_demanglers 980: 08 00 23 a0 ldl t0,8(t2) 984: 08 00 20 e4 beq t0,9a8 988: 02 04 e1 47 mov t0,t1 98c: 00 00 fe 2f unop 990: a1 05 50 40 cmpeq t1,a0,t0 994: 18 00 63 20 lda t2,24(t2) 998: 05 00 20 f4 bne t0,9b0 99c: 08 00 23 a0 ldl t0,8(t2) 9a0: 02 04 e1 47 mov t0,t1 9a4: fa ff 3f f4 bne t0,990 9a8: 00 04 ff 47 clr v0 9ac: 01 80 fa 6b ret 9b0: 00 00 3d 24 ldah t0,0(gp) 9b0: GPRELHIGH current_demangling_style 9b4: 00 04 e2 47 mov t1,v0 9b8: 00 00 41 b0 stl t1,0(t0) 9b8: GPRELLOW current_demangling_style 9bc: 01 80 fa 6b ret (full dumps on request) Now, is it gcc emitting wrong assembler or the linker not knowing how to handle this? Or something totally different? bash-2.04$ gcc -v Reading specs from /usr/lib/gcc-lib/alphaev6-unknown-linux-gnu/3.3/specs Configured with: ../gcc/configure --prefix=/usr --enable-languages=c,c++ --enable-threads Thread model: posix gcc version 3.3 20021017 (experimental) bash-2.04$ ld --version GNU ld version 2.13.90.0.10 20021010 Copyright 2002 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License. This program has absolutely no warranty. bash-2.04$ ls -l /lib/libc*so -rwxr-xr-x 1 root root 25818108 Oct 11 23:45 /lib/libc-2.3.so -rwxr-xr-x 1 root root 119551 Oct 11 23:45 /lib/libcrypt-2.3.so [...] Bye, Thorsten -- | Thorsten Kranzkowski Internet: dl8bcu@dl8bcu.de | | Mobile: ++49 170 1876134 Snail: Niemannsweg 30, 49201 Dissen, Germany | | Ampr: dl8bcu@db0lj.#rpl.deu.eu, dl8bcu@marvin.dl8bcu.ampr.org [44.130.8.19] |