This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Symbol visibility question


Jeff Law <law@redhat.com> writes:

> I need to create a trivial little function that svc_{tcp,udp,unix} can use
> for failures.  Let's call it __svc_accept_failed.
>
> That function needs to be visible to the svc_{tcp,udp,unix}.c files, but
> must not be visible outside glibc or sunrpc.

Since it's just an internal function no visibility settings are needed.
It needs to start with __ to be clean for static linking, but that's
all.  (See __internal_statvfs for an existing example.)

> Unfortunately, I have found any glibc internals documentation on how to do
> this.  I see various libc_hidden_proto, libc_hidden_def macros, but no
> documentation on how to use them.

Those macro are used to add internal aliases to publicly visible
symbols, which is not relevant here.

Andreas.

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]