关于l ibrary not found for -lz.1.2.3 编译错误

简介:

今天在下载一个Demo编译时,提示如下错误

ld: library not found for -lz.1.2.3 collect2: ld returned 1 exit status Command /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2 failed with exit code 1 



lz.1.2.3指的是libz.1.2.3.dylib动态库文件,这是因为iOS5以后,也就是xcode4.2以后就没有libz.1.2.3.dylib了,取而代之是libz.1.2.5.dylib;


解决办法:删除libz.1.2.3.dylib,添加libz.1.2.5.dylib,运行成功,如果直接在原来工程上添加libz.1.2.5.dylib,仍会编译错误,所以要删除libz.1.2.3.dylib;


     本文转自新风作浪 51CTO博客,原文链接:http://blog.51cto.com/duxinfeng/1208685 ,如需转载请自行联系原作者


相关文章
C++ 编译错误 error: ‘cout‘ was not declared in this scope (摄氏度与华氏度的转换)
C++ 编译错误 error: ‘cout‘ was not declared in this scope (摄氏度与华氏度的转换)
C++ 编译错误 error: ‘cout‘ was not declared in this scope (摄氏度与华氏度的转换)
|
C++
VS编译错误:error C2143: 语法错误 : 缺少“;”(在“类型”的前面)
VS编译错误:error C2143: 语法错误 : 缺少“;”(在“类型”的前面)
251 0
解决办法:look up error: undefined symbol
解决办法:look up error: undefined symbol
239 0
|
Java 数据库 Android开发
Eclipse中出现Syntax error on token "class", invalid VariableDeclarator(关键字问题)
Eclipse中出现Syntax error on token "class", invalid VariableDeclarator(关键字问题)
112 0
Eclipse中出现Syntax error on token "class", invalid VariableDeclarator(关键字问题)
|
程序员 C++ 编译器
error LNK2005 已经在***.obj中定义 的解决办法
为什么会出现这个错误??“error LNK2005: 已经在aaa.obj中定义” 编程中经常能遇到LNK2005错误——重复定义错误,其实LNK2005错误并不是一个很难解决的错误。弄清楚它形成的原因,就可以轻松解决它了。
3785 0
configure: error: readline library not found/libreadline.so: undefined reference to tputs
configure: error: readline library not found/libreadline.so: undefined reference to tputs
319 0