Unresolved externals despite linking in zlib.lib

后端 未结 8 969
礼貌的吻别
礼貌的吻别 2020-12-05 23:25

I\'ve been trying to compile an application which utilizes zlib compression in VC++ 2010.

I get the

error LNK2019: unresolved external symbol _infla         


        
相关标签:
8条回答
  • 2020-12-05 23:54

    in my case, install zlib-vc140-static-64 (v1.2.11) or zlib_native (v1.2.11) using NuGet within vs2017.

    0 讨论(0)
  • 2020-12-05 23:55

    Did you verify that your zlib function prototypes are in an extern "C" block? If not, then the linker will be looking for functions with C++-mangled names, while zlib.lib will contain the unmangled C names.

    0 讨论(0)
提交回复
热议问题