Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / Managed C++ / June 2005

Tip: Looking for answers? Try searching our database.

Dyanmic or link or static?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Egbert Nierop \(MVP for IIS\) - 10 Jun 2005 10:25 GMT
Hi,

I use the llib library from adler and compiled it myself.
First I build the lib configuration, then I included zlib.h in stdafx.h and
I added a lib reference
C:\Data\zip\zlib-1.2.2\projects\visualc6\Win32_LIB_Release\zlib.lib

The implementation works. That's the good news.

But to my surprise, my original DLL with implementation grew 40 Kb in size.
So it looks as if the zlib.dll statically is linked and when I use
depends.exe no link has been made to zlib.dll

Can someone explain to me please what setting exactly makes this happen?

Thanks
Tamas Demjen - 10 Jun 2005 17:11 GMT
I use zlib too all the time. Here's how it works. If you link zlib.lib,
it's a static lib that doesn't require the DLL, it links the entire code
to your executable. If you link zdll.lib, that's merely an import
library for zlib1.dll. It's your choice to decide whether you want to
link the static lib or the import lib for the DLL.

Hope this helps,
Tom

Egbert Nierop (MVP for IIS) wrote:
> Hi,
>
[quoted text clipped - 12 lines]
>
> Thanks
Egbert Nierop \(MVP for IIS\) - 11 Jun 2005 13:56 GMT
>I use zlib too all the time. Here's how it works. If you link zlib.lib,
>it's a static lib that doesn't require the DLL, it links the entire code to
[quoted text clipped - 3 lines]
>
> Hope this helps,

Sure it did.
Thanks.

> Tom
>
> Egbert Nierop (MVP for IIS) wrote:
>> Hi,

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.