This is the mail archive of the cygwin-developers mailing list for the Cygwin 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: RFC: Cygwin 64 bit?


On Jun 28 23:45, Thomas Wolff wrote:
> Am 28.06.2011 23:36, schrieb Ryan Johnson:
> >>On Jun 28 22:36, Thomas Wolff wrote:
> >>>Can't cygwin compilation ensure that the cygwin1.dll is always
> >>>loaded first so it could take care of this (if only by then adding
> >>>to the path)?
> >>>(I guess the answer may be no because Windows is juggling with
> >>>the DLLs...)
> >>[...]
> >The answer is definitely "no." Windows can map dlls in any order
> >it pleases, and is only semi-required to initialize them in
> >dependency order (because dlls are often circular dependent
> >anyway). In particular, dlls which suffer base address collisions
> >tend to be loaded before cygwin1.dll
> >
> Last feable attempt: So why does cygwin have to let Windows load the
> DLLs at all? Couldn't the programs just have a stub that uses a
> dedicated version of dlopen for dynamic linking?

In theory, yes.  Every libfoo.dll.a would have to point back to Cygwin
and Cygwin could call LoadLibrary/GetProcAddress so that there's no
explicit load-time linking anymore as far as Cywin DLLs are concerned.
That requires support by gcc/binutils/libtool(?) when building shared
libs, though.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat


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