This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: Problem with DLLs and processes
- From: Brian Dessent <brian at dessent dot net>
- To: cygwin at cygwin dot com
- Date: Wed, 28 Jan 2004 03:56:50 -0800
- Subject: Re: Problem with DLLs and processes
- Organization: My own little world...
- References: <OFE433A7FD.578BD292-ON80256E28.00452205@db.com>
- Reply-to: cygwin at cygwin dot com
Przemyslaw Sliwa wrote:
>
> Woooooww,
>
> It seems it is much more complicated than just the simple STATIC option in GCC under Linux.
> But there must be a way to link the executable with the dlls. Like in Linux.
No, there really isn't a way. You cannot compare the two situations
because they are not the same thing. When you link against a dynamic
library under linux all you're doing is dynamically linking to functions
so that they can be called from your code. But the Cygwin DLL provides
an entire POSIX emulation layer between your program and Windows. This
means that when it starts up it does a number of initialization tasks,
including creating its own segment of shared memory, common to all
Cygwin apps, to maintain state information, tables of handles,
processes, etc. In other words there's a lot of magic going on in the
background to provide you with that spiffy POSIX interface, and it's not
so simple as saying "Why can't I just link statically?"
Brian
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/