Bug 7608 - libgcj build fails
Summary: libgcj build fails
Status: RESOLVED INVALID
Alias: None
Product: gcc
Classification: Unclassified
Component: bootstrap (show other bugs)
Version: 3.2
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords: build, documentation
: 12061 (view as bug list)
Depends on:
Blocks:
 
Reported: 2002-08-15 18:16 UTC by gregd
Modified: 2003-09-08 08:08 UTC (History)
4 users (show)

See Also:
Host: sparc-sun-solaris2.8
Target: sparc-sun-solaris2.8
Build: sparc-sun-solaris2.8
Known to work:
Known to fail:
Last reconfirmed: 2003-08-04 02:44:33


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description gregd 2002-08-15 18:16:01 UTC
% gcc -v
Reading specs from /tools/gcc/3.1.1/sun4u-5.8/lib/gcc-lib/sparc-sun-solaris2.8/3.1.1/specs
Configured with: ../gcc-3.1.1/configure --prefix=/tools/gcc/3.1.1/sun4u-5.8 --srcdir=../gcc-3.1.1 --with-gnu-as --
with-as=/tools/gcc/3.1.1/sun4u-5.8/bin/as --with-gnu-ld --with-ld=/tools/gcc/3.1.1/sun4u-5.8/bin/ld --disable-shar
ed --disable-libgcj
Thread model: posix
gcc version 3.1.1

% ld --version
GNU ld 2.9.1

% as --version
GNU assembler 2.9.1

% make --version
GNU Make version 3.79.1, by Richard Stallman and Roland McGrath.
Built for sparc-sun-solaris2.8

% setenv GCC_B_VER 3.2
% ../gcc-${GCC_B_VER}/configure \
? --prefix=/tools/gcc/${GCC_B_VER}/`uname -m`-`uname -r` \
? --srcdir=../gcc-${GCC_B_VER} --with-gnu-as \
? --with-as=/tools/gcc/${GCC_B_VER}/`uname -m`-`uname -r`/bin/as \
? --with-gnu-ld \
? --with-ld=/tools/gcc/${GCC_B_VER}/`uname -m`-`uname -r`/bin/ld \
? --disable-shared
% make

...everything fine untile here...

creating libgcj.la
(cd .libs && rm -f libgcj.la && ln -s ../libgcj.la libgcj.la)
/bin/sh ./libtool --tag=GCJ --mode=link /tools/src/gcc/gcc-3.2-sun4u-5.8/gcc/gcj -B/tools/src/gc
c/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8/sparcv9/libjava/ -B/tools/src/gcc/gcc-3.2-sun4u-5.8/gcc
/ -L/tools/src/gcc/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8/sparcv9/libjava -g -O2  -m64 -m64 -o j
v-convert --main=gnu.gcj.convert.Convert -rpath /tools/gcc/3.2/sun4u-5.8/lib/sparcv9 -shared-lib
gcc   -L/tools/src/gcc/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8/sparcv9/libjava/.libs libgcj.la 
/tools/src/gcc/gcc-3.2-sun4u-5.8/gcc/gcj -B/tools/src/gcc/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8
/sparcv9/libjava/ -B/tools/src/gcc/gcc-3.2-sun4u-5.8/gcc/ -g -O2 -m64 -m64 -o jv-convert --main=
gnu.gcj.convert.Convert -shared-libgcc  -L/tools/src/gcc/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8/
sparcv9/libjava -L/tools/src/gcc/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8/sparcv9/libjava/.libs ./
.libs/libgcj.a -L/tools/src/gcc/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8/sparcv9/libstdc++-v3/src 
-L/tools/src/gcc/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8/sparcv9/libstdc++-v3/src/.libs -lpthread
 -lrt -ldl -L/tools/src/gcc/gcc-3.2-sun4u-5.8/gcc/sparcv9 -L/tools/src/gcc/gcc-3.2-sun4u-5.8/gcc
 -L/tools/gcc/3.2/sun4u-5.8/sparc-sun-solaris2.8/bin -L/tools/gcc/3.2/sun4u-5.8/sparc-sun-solari
s2.8/lib -L/usr/ccs/bin/sparcv9 -L/usr/ccs/bin -L/usr/ccs/lib/sparcv9 -L/usr/ccs/lib -L/lib/spar
cv9 -L/usr/lib/sparcv9 -lgcc -lgcc -Wl,--rpath -Wl,/tools/gcc/3.2/sun4u-5.8/lib/sparcv9
./.libs/libgcj.a(jni.o):itimerspec/../../../../gcc-3.2/libjava/jni.cc:2166: relocation truncated
 to fit: R_SPARC_DISP32 .gnu.linkonce.t._Z34_Jv_GetArrayElementFromElementTypePN4java4lang6Objec
tEPNS0_5ClassE
./.libs/libgcj.a(natObject.o):itimerspec/include/java-threads.h:131: relocation truncated to fit
: R_SPARC_DISP32 .gnu.linkonce.t._Z34_Jv_GetArrayElementFromElementTypePN4java4lang6ObjectEPNS0_
5ClassE
./.libs/libgcj.a(natSystem.o):itimerspec/../../../../gcc-3.2/libjava/java/lang/natSystem.cc:107:
 relocation truncated to fit: R_SPARC_DISP32 .gnu.linkonce.t._Z34_Jv_GetArrayElementFromElementT
ypePN4java4lang6ObjectEPNS0_5ClassE
collect2: ld returned 1 exit status
make[4]: *** [jv-convert] Error 1
make[4]: Leaving directory `/tools/src/gcc/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8/sparcv9/libjav
a'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/tools/src/gcc/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8/sparcv9/libjav
a'
make[2]: *** [multi-do] Error 1
make[2]: Leaving directory `/tools/src/gcc/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8/libjava'
make[1]: *** [all-multi] Error 2
make[1]: Leaving directory `/tools/src/gcc/gcc-3.2-sun4u-5.8/sparc-sun-solaris2.8/libjava'
make: *** [all-target-libjava] Error 2

Release:
3.2

Environment:
SunOS 5.8 Generic_108528-13 sun4u sparc SUNW,Sun-Blade-1000

How-To-Repeat:
Same error everytime try to compile libgcj...  could not find a solution after google searches (but not extensive)
Comment 1 Andrew Pinski 2003-05-25 21:56:24 UTC
Can you try to bootstrap gcc 3.3, since 3.2 is no longer supported or being updated?
Comment 2 Dara Hazeghi 2003-06-13 14:14:56 UTC
Eric,

you recently dealt with something similar to this. Does this appear to be a duplicate of the broken 
Sun assembler problem? Thanks,

Dara
Comment 3 Eric Botcazou 2003-06-13 15:04:28 UTC
No, rather of broken GNU binutils and/or misconfiguration.

According to http://gcc.gnu.org/install/specific.html#*-*-solaris2*, all GNU
binutils prior to 2.11.2 have known bugs on Solaris. Moreover, CONFIG_SHELL must
be set to /bin/ksh in the environment before configuring.
Comment 4 gregd 2003-06-13 17:33:59 UTC
Subject: Re:  libgcj build fails


I have not tried this like I said I would.  I believe I will have time 
this weekend and let you know by Monday.  I will make sure I use the 
latest binutils.

Cheers,
Greg


Comment 5 Dara Hazeghi 2003-07-18 18:56:27 UTC
Looks an awful lot like what Alan fixed in binutils (I'm presuming 2.14): http://mail.gnu.org/
archive/html/bug-gnu-utils/2002-09/msg00263.html. Eric, perhaps we should update the 
required binuilts for Solaris?
Comment 6 Eric Botcazou 2003-07-18 19:31:26 UTC
Subject: Re:  libgcj build fails

> Looks an awful lot like what Alan fixed in binutils (I'm
> presuming 2.14):
> http://mail.gnu.org/archive/html/bug-gnu-utils/2002-09/msg00263.html.

Indeed.

> Eric, perhaps we should update the required binuilts for Solaris?

Probably, but I'm not the best person to ask since I don't use GNU binutils 
on Solaris. Maybe ask Alan directly?

Comment 7 Dara Hazeghi 2003-07-18 20:19:01 UTC
Alan, you fixed a bug much like the one in this report last September as a binutils bug. To avoid 
having this problem re-reported, should we recommend a certain minimum version of binutils on 
Solaris in the install documentaton? Thanks,

Dara
Comment 8 Alan Modra 2003-07-19 03:34:30 UTC
I made another fix on 2003-06-19.  See
http://sources.redhat.com/ml/binutils/2003-06/msg00679.html
Unfortunately, this was after the 2.14 release, and means we don't have an
offical binutils release with the fix.  2.14.1 will contain the fix, as will
2.15.  Meanwhile 64 bit Sparc can use CVS mainline binutils, or one of HJ's
recent releases.
Comment 9 Andrew Pinski 2003-08-04 02:44:33 UTC
Already analysised by Alan Modra, just need a new version of binutils (but a currently 
unreleased one).
Comment 10 Andrew Pinski 2003-08-26 13:14:14 UTC
*** Bug 12061 has been marked as a duplicate of this bug. ***
Comment 11 Eric Botcazou 2003-09-08 08:08:06 UTC
This is a binutils bug.