尝试将libz.1.2.3.dylib添加到我的ipad项目时出现问题 [英] Problems trying to add the libz.1.2.3.dylib to my ipad project

查看:117
本文介绍了尝试将libz.1.2.3.dylib添加到我的ipad项目时出现问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

首先,我现在在这个网站上真的很抱歉,如果我提交了一些错误发布这个问题。我正在尝试使用zipArchive类来管理ipad项目中的zip文件。

First of all, i'm now on this site so really sorry if i'm commiting some error posting this question.I'm trying to use the zipArchive class to manage zip files in an ipad project.

哪些步骤会重现问题?


  1. 创建项目。

  1. Create a project.

将ZipArchive文件夹及其文件添加。

Add the ZipArchive folder with their files.

添加libz.1.2.3.dylib

Add the libz.1.2.3.dylib

预期产量是多少?你看到了什么?

What is the expected output? What do you see instead?

我已经注释了所有代码(关于ziparchive),所以我只有#import #importZipArchive / ZipArchive.h viewcontroller,我希望没有错误地构建项目。

I have all the code (about ziparchive) commented, so i only have the #import #import "ZipArchive/ZipArchive.h" in my viewcontroller, and i expect to build the project without errors.

我在编译器中看到以下错误:

I see the following error in the compiler:

ld:警告:忽略文件/Developer/Platforms/iPhoneOS.platform/DeviceSupport/4.2/Symbols/usr/lib/libSystem.dylib,文件
ld:in / Developer / Platforms / iPhoneOS中缺少必需的体系结构i386。 platform / DeviceSupport / 4.2 / Symbols / usr / lib / libobjc.A.dylib,在架构i386的文件中缺少必需的体系结构i386
collect2:ld返回1退出状态
Command / Developer / Platforms / iPhoneSimulator。 platform / Developer / usr / bin / llvm-gcc-4.2以退出代码1失败

ld: warning: ignoring file /Developer/Platforms/iPhoneOS.platform/DeviceSupport/4.2/Symbols/usr/lib/libSystem.dylib, missing required architecture i386 in file ld: in /Developer/Platforms/iPhoneOS.platform/DeviceSupport/4.2/Symbols/usr/lib/libobjc.A.dylib, missing required architecture i386 in file for architecture i386 collect2: ld returned 1 exit status Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2 failed with exit code 1

您使用的是哪个版本的产品?在什么操作系统?
我在Mac OS X版本10.6.7上使用xcode 4一个用于ipad和4.2 ipad模拟器的项目

What version of the product are you using? On what operating system? I'm using xcode 4 a project for the ipad with the 4.2 ipad simulator on a Mac os X version 10.6.7

请在下面提供任何其他信息。
我认为问题出在libz.1.2.3.dylib库中,我有一些客人可能会遇到问题:

Please provide any additional information below. I think the problem is with the libz.1.2.3.dylib library, and I have some guest of where might be the problem:


  1. libz.1.2.3.dylib路径错误在iPhoneSimulator.platform上,它对ipad也有效吗?如果不是,我可以将哪个lib用于与ipad相同的目的?

  1. The libz.1.2.3.dylib path error is on iPhoneSimulator.platform, it is valid for ipad too?? If is not, which lib could i use for the same purpose with the ipad??

我不确定我是否正在添加libz.1.2。 3.dylib lib正确。我所做的是:右键单击Resources文件夹 - >将文件添加到myproject - >搜索libz.1.2.3.dylib并从编译器错误中可以看到的路径添加它的4.2版本。我也尝试添加到具有相同结果的frameworks文件夹。

I'm not sure i'm adding the libz.1.2.3.dylib lib correctly. What I have done is: right-click on Resources folder -> add files to "myproject" -> search for the libz.1.2.3.dylib and add the 4.2 version of it from the path u could see in the compiler errors. I also try to add to the frameworks folder with the same results.

我正在阅读很多关于如何发布的帖子修复类似的问题,但没有人可以帮助我。

I'm reading lots of posts about how to fix similar problems but no one could help me.

我知道我必须做些什么来解决我的问题?

Any idea of what I have to do to fix my problem??

非常感谢!!

推荐答案

你需要这样做:


  1. 从本地Frameworks文件夹中删除libz.1.2.3。您不需要它。

  2. 在Project Navigator顶部选择您的项目。

  3. 选择您的应用程序目标。

  4. 打开Link Binary with Libraries。

  5. 点击+

  6. 搜索libz。

  7. 选择libz.dylib。

  1. Delete libz.1.2.3 from your local Frameworks folder. You don't need it.
  2. Select your project at the top of the Project Navigator.
  3. Select your application target.
  4. Open "Link Binary With Libraries".
  5. Click the "+"
  6. Search for "libz".
  7. Select "libz.dylib".

如果您使用的是Xcode 4.5.2,则可能是以下屏幕截图你可以帮助你完成第2步到第5步。我不确定其他版本的Xcode是否相同。

If you are using Xcode 4.5.2 the screenshots below may aide you in proceeding through steps 2 through 5. I'm not sure if other versions of Xcode are the same or not.

这篇关于尝试将libz.1.2.3.dylib添加到我的ipad项目时出现问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆