This is the mail archive of the libc-help@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: libc inicialization


On 13 October 2012 07:38, César <divcesar@gmail.com> wrote:
> 1. What should be the register values at the time of invocation of
> libc init routines? And what should be the stack content?

glibc is initialized like any other library, with the exception that
it access some static variables that the loader makes available.  The
stuff you have implemented should be sufficient, i.e. argc, argv, envp
and auxv since that is what the kernel sets up for the loader.

> 2. Does libc interact with the loader? How? Does glibc access the PCB
> (process control block)?

glibc interacts with the loader through some variables and functions
that the loader exports specifically for glibc.  The task structure is
a kernel level construct, so userspace applications and libraries
(including glibc and the loader) cannot access it directly.

-- 
http://siddhesh.in


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