开发者

Xcode cannot resolve zlib symbols

开发者 https://www.devze.com 2023-03-08 13:14 出处:网络
I use the zlib library to do data compression in a command line tool for Mac. On Xcode 4, I get an error \"undefined symbol\" on zlib functions.

I use the zlib library to do data compression in a command line tool for Mac.

On Xcode 4, I get an error "undefined symbol" on zlib functions.

I search for the 开发者_开发问答libz.dylib on mac computer and I find 3 files in /Developer/Platforms/iPhoneOS.platform.

Nothing in /Developer/Platforms/MacOSX.platform.

Why? Where I can find my libz.dylib library for architeture i386?


In Xcode 4 have a look at your Build Phases.

Go to the 3rd section - Link Binary with libraries

Click the + button

choose libz.dylib in the drop down.

Xcode cannot resolve zlib symbols


You can download zlib from its site, look further down in the page for the download links.

You can also happen to have installed macports or fink. In this case, you get there prebuilt versions.

0

精彩评论

暂无评论...
验证码 换一张
取 消