Xcode 4 - 归档应用程序时出现链接错误
我们已经使用 Xcode 4 和 LLVM 2.0 几个月了,在完成对应用程序的巨大更新后,我们认为应该将其发送给 Apple。
然而,我们无法想象的是,虽然该程序能够为模拟器和设备构建,但在归档时,XCode 只是抛出了一个令人讨厌的链接错误,让我们陷入困境。
该错误与 ZipKit 库 有关(我们之前讨论过 遇到的问题使其在 XCode 4 下工作)。
这就是我们得到的结果:
ld: library not found for -ltouchzipkit
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Command /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/clang failed with exit code 1
所以问题是:我们是否需要更改构建良好的应用程序的任何设置才能也能够存档?
We have been using Xcode 4 and LLVM 2.0 for a couple of months now and after finishing a huge update to our application we thought we would send it off to Apple.
What we couldn't imagine however, was that although the program was able to be built for both the simulator and devices, when it came to archiving, XCode just threw a nasty linking error and left us hanging there.
The error is related to the ZipKit library (we previously discussed the issues we had with making it work under XCode 4).
This is what we get:
ld: library not found for -ltouchzipkit
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Command /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/clang failed with exit code 1
So the question is: do we need to change any settings for an app that builds fine to be able to get archived as well?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
不想翻转,但看起来问题是链接器找不到名为“touchzipkit”的库。事实上,这个问题仅在您存档时出现,似乎表明您的目标具有(至少一个)构建设置,该设置具有不同的“调试”和“发布”值......并且“发布”值已损坏。
由于不熟悉 ZipKit,我只是在黑暗中拍摄。但我会开始一一检查您的构建设置,特别注意调试和发布设置不同的库搜索路径和编译器标志。
Not trying to be flip, but it looks like the problem is that the linker can't find a library called "touchzipkit". The fact that this problem only comes up when you archive would seem to indicate your target has (at least one) build setting that has different values for "debug" and "release"... and that the "release" value is broken.
Not being familiar with ZipKit, I'm just shooting in the dark here. But I'd start checking out your build settings one by one, paying particular attention to library search paths and compiler flags where the debug and release settings are different.