Question

I've been struggling to compile my Visual C++ 2010 project with dependency of Zlib. I've got source code that worked on Linux and Mac OS X. Here's, where I have linker errors:

error LNK2019: unresolved external symbol _inflate@8 referenced in function...
error LNK2019: unresolved external symbol _inflateInit2_@16 referenced in function...
error LNK2019: unresolved external symbol _deflate@8 referenced in function...
error LNK2019: unresolved external symbol _deflateInit2_@32 referenced in function...

I've been finding solution for few days now, trying compiling Zlib different ways, but it is clear that I've missed something. Very similar question has been answered here, but not clearly enough for amateur like me. I would need step-by-step guide how to get it to work.

Thank you in advance.

Was it helpful?

Solution

If you have static libraries after building the Zlib, point them in your project at this location.Project properties -> Linker -> Input -> Additional dependencies. Give the absolute path.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top