【发布时间】:2010-09-22 07:15:05
【问题描述】:
我在我的 iphone 应用程序中包含了<zlib.h> 以及我正在模拟 Brad Larson 提供的 Molecules 示例代码的源代码,但是,当我构建项目时,它返回如下错误。谁能帮我指出这是图书馆链接问题还是我遗漏了什么?
"_deflate", referenced from: -[NSData(Gzip) gzipDeflate] in NSData+Gzip.o "_inflateEnd",
referenced from: -[NSData(Gzip) initWithGzippedData:] in NSData+Gzip.o "inflateInit2",
referenced from: -[NSData(Gzip) initWithGzippedData:] in NSData+Gzip.o "_inflate",
referenced from: -[NSData(Gzip) initWithGzippedData:] in NSData+Gzip.o "_deflateEnd",
referenced from: -[NSData(Gzip) gzipDeflate] in NSData+Gzip.o "deflateInit2", referenced
from: -[NSData(Gzip) gzipDeflate] in NSData+Gzip.o ld: symbol(s) not found collect2: ld
returned 1 exit status
【问题讨论】:
-
您是否将 libz 添加到您的项目中?