This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Statically linked binary & NSS
- To: Lionel dot Cons at cern dot ch
- Subject: Re: Statically linked binary & NSS
- From: Nick Ing-Simmons <nik at tiuk dot ti dot com>
- Date: Thu, 3 Dec 1998 09:23:19 GMT
- Cc: egcs at cygnus dot com, drepper at cygnus dot com (Ulrich Drepper), Philippe Defert <philippe dot defert at cern dot ch>, bug-glibc at gnu dot org
- Organization: via, but not speaking for : Texas Instruments Ltd.
- References: <199812020930.KAA03751@mercury.cern.ch> <r2yaoq8sjg.fsf@happy.cygnus.com> <199812021637.RAA07111@mercury.cern.ch>
- Reply-To: Nick Ing-Simmons <nik at tiuk dot ti dot com>
Lionel Cons <Lionel.Cons@cern.ch> writes:
>Ulrich Drepper writes:
> > Lionel Cons <Lionel.Cons@cern.ch> writes:
> >
> > > I would like to create a statically linked binary but it seems that
> > > the -static flag is not enough.
> >
> > Using NSS and -static contradict each other. NSS always requires
> > dynamic loading.
>
>Why can't I link all the libnss_* libraries statically so that a
>dynamic loading is not needed anymore? I don't see any technical
>problem that would prevent this. The code calling the right routines
>in the right libraries just has to be careful...
Assuming NSS is "Name Service Switch: then that chooses which version of
function(s) to _load_ based on the config file.
It dynamic loads the appropriate library, which in turn needs the root
executable to have the right hooks.
--
Nick Ing-Simmons <nik@tiuk.ti.com>
Via, but not speaking for: Texas Instruments Ltd.