cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Using libcurl with zlib

From: Gisle Vanem <gvanem_at_broadpark.no>
Date: Thu, 10 May 2012 13:35:50 +0200

"east2006 east2006" <east2006_at_gmail.com> wrote:

> 1>libcurl.lib(content_encoding.obj) : error LNK2019: unresolved external
> symbol _zlibVersion_at_0 referenced in function _Curl_unencode_gzip_write
> 1>.\Standalone-D\MelodoContent.exe : fatal error LNK1120: 5 unresolved
> externals
>
>
> I'm staticly compiling libcurl with zlib (1.2.3) by including zlib.lib and
> adding preprocessors:
>
> HAVE_ZLIB_H
> HAVE_ZLIB
> HAVE_LIBZ

Somehow you seems to have built libcurl with '-DZLIB_WINAPI' while
zlib.lib was built without this. How have you built libcurl? Alternatively
build zlib with '-DZLIB_WINAPI'.

Either way, the linker in your case expects __stdcall imports. I.e.
the '@x' suffixes.

--gv
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2012-05-10