`Hiding' libc symbols

Jacques A. Vidrine nectar at FreeBSD.org
Tue May 6 08:25:57 PDT 2003


On Tue, May 06, 2003 at 07:53:39AM -0700, Terry Lambert wrote:
> Perhaps instead of asking how to prevent symbol replacement, one
> should be asking how to get rid of incestuous functions in the
> library implementation for standard library functions.
> 
> No, I do not expect "_fmt" (or whatever) to go away from common
> code in printf/sprintf/whatever.  But I do expect it to be "_fmt"
> instead of "fmt", i.e. in implementation space, rather than in
> the symbol space legal for users to use.

This is exactly what I wish to achieve.  This is exactly the approach
that I took with strlcpy [1]:  the internal implementation is called
`_strlcpy', while the exported symbol remains `strlcpy'.

Cheers,
-- 
Jacques Vidrine   . NTT/Verio SME      . FreeBSD UNIX       . Heimdal
nectar at celabo.org . jvidrine at verio.net . nectar at freebsd.org . nectar at kth.se

[1] Before I backed it out in an attempt to demonstrate good will.


More information about the freebsd-arch mailing list