[PATCH] Rename pwait for LynxOS

Zack Weinberg zack@codesourcery.com
Tue Aug 17 21:26:00 GMT 2004


Adam Nemet <anemet@lnxw.com> writes:

>> Why is libc's pwait() getting pulled in at all?  If libiberty is
>> providing one, there's no reason for libc's pwait() to be needed.
>
> Well, the two pwait's are identical only in name.  They have different
> prototypes and different functionalities otherwise.  For the actual
> error, see the bottom of
> http://gcc.gnu.org/ml/gcc-patches/2004-08/msg01182.html.
>
> And pwait is packaged with system into one member of libc.a.

That's arguably a bug in libc - use of system() should not cause the
user program to be unable to use the name pwait, which is not reserved
by the C standard.

> The definition of system is included because of tlink.o.

That suggests another potential fix, which is to change tlink.c to use
pexecute instead of system, thus preventing libc's pwait from being
dragged in.

zw



More information about the Gcc-patches mailing list