Page 1 of 1

Staticaly linking of Zlib

Posted: Thu May 23, 2013 11:42 am
by Raider
How to stacitaly link Zlib with RFC 2.0?
It was all fine with 1.3.1, but with 2.0 zlib.dll is required :(
The reason is I need to build application with single .exe file in distribution.

Re: Staticaly linking of Zlib

Posted: Thu May 23, 2013 2:00 pm
by jarl
Whoops - that's a use case we missed... I'll put some code into the next release to allow you to link zlib statically as well. Thanks for reporting this.

Re: Staticaly linking of Zlib

Posted: Fri May 24, 2013 9:35 am
by Raider
Thanks a lot. Waiting for a new version.

Re: Staticaly linking of Zlib

Posted: Tue Jun 04, 2013 12:43 am
by jarl
A new release is out (2.0.0.2682)

http://www.deltavsoft.com/doc/rcf_user_ ... Notes.html

If you define RCF_ZLIB_STATIC in your build, you'll be able to compile zlib directly into your executable.

Re: Staticaly linking of Zlib

Posted: Thu Jun 06, 2013 8:52 pm
by Raider
RCF_ZLIB_STATIC and RCF_ZLIB_STATIC=1 doesnot help :(
I'm getting "Unable to load library. Library name: zlib.dll" exception (RcfError_DllLoad) inside ZlibDll::ZlibDll(), i.e. before ZlibDll::loadFunctionPtrs() call (where RCF_ZLIB_STATIC comes into action)

Re: Staticaly linking of Zlib

Posted: Fri Jun 07, 2013 2:42 am
by jarl
Sorry about that. The test harness happened to have the zlib DLL available, so I didn't notice that it was being loaded.

I've uploaded 3 files:

include/RCF/DynamicLib.hpp
src/RCF/OpenSslEncryptionFilter.cpp
src/RCF/ZlibCompression.cpp

If you copy these into your RCF distribution, it should fix the problem. The changes will be in the next build as well.

Re: Staticaly linking of Zlib

Posted: Fri Jun 07, 2013 2:00 pm
by Raider
It works! Thanks a lot!