From: Alexandre Oliva <aoliva@redhat.com>
To: Gabriel Dos Reis <gdr@integrable-solutions.net>
Cc: Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>,
gcc@gcc.gnu.org, java@gcc.gnu.org, Joe Buck <jbuck@synopsys.com>,
Eric Botcazou <ebotcazou@libertysurf.fr>,
"H. J. Lu" <hjl@lucon.org>
Subject: Re: 3.2.3-pre tarball 2: libjava build still fails on sparc-sun-solaris2.8
Date: Wed, 23 Apr 2003 19:03:00 -0000 [thread overview]
Message-ID: <oradehax51.fsf@localhost.localdomain> (raw)
In-Reply-To: <m34r4sm19q.fsf@uniton.integrable-solutions.net>
[-- Attachment #1: Type: text/plain, Size: 1462 bytes --]
On Apr 21, 2003, Gabriel Dos Reis <gdr@integrable-solutions.net> wrote:
> Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at> writes:
> | Interestingly, my problem is libtool-related as well.
I find this reasoning interesting... It is as libtool-related as
make-related and shell-related, if you ask me. I mean, you're
starting from a shell, right? And it is make that starts libtool,
right? And libtool starts the linker, right? And the linker fails
because it's buggy. So... It's pretty obvious that it's libtool's
fault, right? :-D
> | I first reported a variant of this problem in
> | http://gcc.gnu.org/ml/gcc/2002-06/threads.html#00284
> | but didn't notice it on the 3.2 branch until now, because I had Java
> | disabled on the slow Solaris boxes. :-(
> Well, it seems that that issue had been debated in-depth; I would really
> appreciate if Alexandre Oliva or Tom Tromey or any libtool-guru could
> jump in and enlighten me.
The one thing that is getting me confused is the long list of object
files in the link command. libtool could use -z allextract instead of
extracting the object files itself. Currently, for some reason,
libtool would use it when using Sun CC, or gcc as a C or Java linker,
but not when using gcc as a C++ linker (I haven't investigated why it
thinks we're doing C++ instead of Java).
Gerald, could you please test whether this patch fixes the problem?
If so, will you please check it into the release branch?
Thanks,
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: libtool-sun-ld-gcc-allextract.patch --]
[-- Type: text/x-patch, Size: 1456 bytes --]
Index: ChangeLog
from Alexandre Oliva <aoliva@redhat.com>
* ltcf-cxx.sh (whole_archive_flag_spec): Use -z allextract on
Solaris 2.6 and above, with GCC and non-GNU ld.
Index: ltcf-cxx.sh
===================================================================
RCS file: /cvs/gcc/gcc/ltcf-cxx.sh,v
retrieving revision 1.25
diff -u -p -r1.25 ltcf-cxx.sh
--- ltcf-cxx.sh 20 Feb 2003 01:11:51 -0000 1.25
+++ ltcf-cxx.sh 23 Apr 2003 18:21:14 -0000
@@ -612,6 +612,16 @@ case $host_os in
# GNU C++ compiler with Solaris linker
if test "$with_gcc" = yes && test "$with_gnu_ld" = no; then
no_undefined_flag=' ${wl}-z ${wl}defs'
+ case $host_os in
+ solaris2.[0-5] | solaris2.[0-5].*) ;;
+ *)
+ # The C++ compiler is used as linker so we must use $wl
+ # flag to pass the commands to the underlying system
+ # linker.
+ # Supported since Solaris 2.6 (maybe 2.5.1?)
+ whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
+ ;;
+ esac
if $CC --version | egrep -v '^2\.7' > /dev/null; then
archive_cmds='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
[-- Attachment #3: Type: text/plain, Size: 290 bytes --]
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{redhat.com, gcc.gnu.org}
CS PhD student at IC-Unicamp oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist Professional serial bug killer
next prev parent reply other threads:[~2003-04-23 18:26 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-04-17 16:56 Joe Buck
2003-04-17 18:15 ` H. J. Lu
2003-04-17 22:16 ` Joe Buck
2003-04-18 16:26 ` Eric Botcazou
2003-04-18 17:18 ` Joe Buck
2003-04-18 17:25 ` Gabriel Dos Reis
2003-04-19 7:42 ` Eric Botcazou
2003-04-21 16:57 ` Joe Buck
2003-04-21 3:36 ` Gerald Pfeifer
2003-04-21 13:54 ` Gabriel Dos Reis
2003-04-23 19:03 ` Alexandre Oliva [this message]
2003-04-23 19:24 ` Joe Buck
2003-04-23 23:35 ` Alexandre Oliva
2003-04-24 16:15 ` Michael S. Zick
2003-04-25 14:45 ` libjava build still fails on sparc-sun-solaris2.9 Gerald Pfeifer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=oradehax51.fsf@localhost.localdomain \
--to=aoliva@redhat.com \
--cc=ebotcazou@libertysurf.fr \
--cc=gcc@gcc.gnu.org \
--cc=gdr@integrable-solutions.net \
--cc=hjl@lucon.org \
--cc=java@gcc.gnu.org \
--cc=jbuck@synopsys.com \
--cc=pfeifer@dbai.tuwien.ac.at \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).