This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: libgcj versus libtool
- To: tromey at cygnus dot com (Tom Tromey)
- Subject: Re: libgcj versus libtool
- From: Alexandre Oliva <oliva at dcc dot unicamp dot br>
- Date: 02 Jul 1999 06:48:22 -0300
- Cc: egcs-patches at egcs dot cygnus dot com, java-patches at sourceware dot cygnus dot com
- Cc: libtool at gnu dot org
- References: <orwvwnrrmd.fsf@saci.lsd.dcc.unicamp.br> <199906291701.KAA23765@ferrule.cygnus.com.> <orso79oocm.fsf@saci.lsd.dcc.unicamp.br> <m10zOxs-000NVRC@creche>
[ About passing -B/pathname/ to gcc when linking ]
On Jun 30, 1999, tromey@cygnus.com (Tom Tromey) wrote:
>>>>>> "Alexandre" == Alexandre Oliva <oliva@dcc.unicamp.br> writes:
>>> On Jun 29, 1999, Tom Tromey <tromey@cygnus.com> wrote:
>>> In the Cygnus tree we use a short patch to libtool instead. This
>>> works everywhere that libtool works.
Alexandre> Would you have that patch handy? It might speed things up :-)
> Here is the rather ugly patch. You'd probably want to remove the
> "CYGNUS LOCAL" markers.
Hmm, the problem is that it assumes gcc. -B may have other meanings,
and we don't always want to pass it down. The ``blessed'' way to pass
arbitrary flags to the compiler, using libtool, is -Wc,-flag or
-Xcompiler -flag (libtool will strip -Wc, and -Xcompiler, if it uses
$CC to link, and will ignore the argument if it calls ld directly).
It also handles -Wl, and -Xlinker, removing them if calling the linker
directly, or keeping -Wl, if running $CC.
This is already implemented in libtool 1.3b, that is likely to be
released today. I understand it might be cumbersome to add -Wc,
before -B, but I don't see any other portable way to go :-(
Well, another option is to arrange that ltconfig stores with_gcc in
the libtool script it generates, and conditionalize the special
handling of -B to with_gcc=yes.
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
{oliva,Alexandre.Oliva}@dcc.unicamp.br aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
*** E-mail about software projects will be forwarded to mailing lists