sinofool/build-libcurl-ios

disable zlib

winster opened this issue · 1 comments

Hello,

First of all thanks to your script. It worked well except when you use following API.

Note: I used darwinssl for my program.

curl_easy_perform()

If I add above API to my program, I got following Mach-O errors in Xcode.

Undefined symbols for architecture arm64:
"_inflate", referenced from:
_inflate_stream in libcurl.a(libcurl_la-content_encoding.o)
"_inflateEnd", referenced from:
_inflate_stream in libcurl.a(libcurl_la-content_encoding.o)
_Curl_unencode_gzip_write in libcurl.a(libcurl_la-content_encoding.o)
_Curl_unencode_cleanup in libcurl.a(libcurl_la-content_encoding.o)

Disabling zlib helped here (found in https://www.bountysource.com/issues/39333978-documentation-missing-to-build-for-ios). I created a pull request with the changes.

You should link with zlib in your application.
HTTP compression is useful and relatively basic feature.

Add "-lz" to your xcode project configuration "Other Linker Flags" should fix the issue you have.