Date: Mon, 22 Jan 2001 14:37:36 -0500 (EST) From: Garrett Wollman <wollman@khavrinen.lcs.mit.edu> To: n@nectar.com Subject: Re: other approach for hiding names (was Re: Request For Review: libc/libc_r changes to allow -lc_r) Message-ID: <200101221937.OAA40991@khavrinen.lcs.mit.edu> In-Reply-To: <mit.lcs.mail.freebsd-arch/20010122120302.A93660@hamlet.nectar.com> References: <mit.lcs.mail.freebsd-arch/20010120153158.A88123@hamlet.nectar.com> <mit.lcs.mail.freebsd-arch/Pine.SUN.3.91.1010120171614.8403A-100000@pcnet1.pcnet.com>
next in thread | previous in thread | raw e-mail | index | archive | help
In article <mit.lcs.mail.freebsd-arch/20010122120302.A93660@hamlet.nectar.com> you write: >Is there somewhere in the build process that we could insert a tool >that does something like the following? > > for each externally visible symbol: This is not unlike what `crunch' does, so it's not impossible. >[1] Actually this list would probably be all ISO C names + other > symbols that require special handling for threads. Or whatever. Actually, no. The only symbols that need to be hidden are the ones actually used inside libc. There are different levels of hiding necessary; for functions used internal to the implementation of the ISO C standard library, all non-ISO-reserved names must be hidden, but for functions used to implement POSIX libraries, only non-POSIX-reserved names (a much smaller set) must be hidden. Of course, it may be more convenient to just do everything. In no circumstances do we need to hide a function that is used solely as an external interface; the linker will (read: is supposed to) do the Right Thing and resolve program-local references using such names to the program and not the library. -GAWollman -- Garrett A. Wollman | O Siem / We are all family / O Siem / We're all the same wollman@lcs.mit.edu | O Siem / The fires of freedom Opinions not those of| Dance in the burning flame MIT, LCS, CRS, or NSA| - Susan Aglukark and Chad Irschick To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200101221937.OAA40991>