Build-side libiberty

Zack Weinberg zack@codesourcery.com
Tue Nov 13 20:40:00 GMT 2001


On Fri, Nov 23, 2001 at 04:53:07PM -0500, DJ Delorie wrote:
> 
> (1) Why are we moving doprnt.c?

Assuming that it is necessary, it belongs in libiberty.  Notice how it
needs a bunch of special-case Makefile junk in the gcc subdirectory,
but none at all in libiberty.

> (2) Why do we have a doprnt.c in the first place?

Well, it was added in 1998, so I don't think it's a total archaism.
libiberty's vprintf/vfprintf/vsprintf all depend on the existence of
_doprnt; if the system library provides none of the above, we're
screwed.  (It may be that there is no such system library, but I
wouldn't bet on it.)

The patch adding it was http://gcc.gnu.org/ml/gcc/1998-04/msg00929.html
(this was back when there was only egcs@egcs.cygnus.com).  See also
discussion in the thread at http://gcc.gnu.org/ml/gcc/1998-03/msg00689.html.

> Also, I was going to be cautious and add the build libiberty first,
> let the dust settle, then switch gcc to using it.  But I'm OK with
> doing both at the same time too.

There wasn't any dust to settle with your patch - the library would
get built, but nothing depended on it to exist, so nothing would
notice if it was broken.  I only found the bug with the wrong
configure arguments because I tried to use the build libiberty and
discovered that it was made of PowerPC object code instead of Sparc.

zw



More information about the Gcc-patches mailing list