2011-02-26 40 views
0

我几乎完成了我的应用程序,但突然一个错误出现苹果推送通知问题的gcc-4.2失败,退出代码1

的错误:

Ld build/urbantest.build/Release-iphoneos/urbantest.build/Objects-normal/armv7/urbantest normal armv7 
cd /Users/mbp/Apps/Testing/urbantest 
setenv IPHONEOS_DEPLOYMENT_TARGET 4.1 
setenv PATH "/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin" 
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc-4.2 -arch armv7 -isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.1.sdk -L/Users/mbp/Apps/Testing/urbantest/build/Release-iphoneos -L/Users/mbp/Apps/Testing/urbantest/Airship -F/Users/mbp/Apps/Testing/urbantest/build/Release-iphoneos -filelist /Users/mbp/Apps/Testing/urbantest/build/urbantest.build/Release-iphoneos/urbantest.build/Objects-normal/armv7/urbantest.LinkFileList -dead_strip -all_load -weak_library /usr/lib/libSystem.B.dylib -miphoneos-version-min=4.1 -framework Foundation -framework UIKit -framework CoreGraphics -lUAirship-1.0.4 -framework AudioToolbox -framework MessageUI -framework CFNetwork -framework CoreTelephony -framework MobileCoreServices -framework Security -framework StoreKit -framework SystemConfiguration -lsqlite3 -lz -o /Users/mbp/Apps/Testing/urbantest/build/urbantest.build/Release-iphoneos/urbantest.build/Objects-normal/armv7/urbantest 

ld: duplicate symbol _OBJC_CLASS_$_UA_ASIDownloadCache in /Users/mbp/Apps/Testing/urbantest/Airship/libUAirship-1.0.4.a(UA_ASIDownloadCache.o) and /Users/mbp/Apps/Testing/urbantest/build/urbantest.build/Release-iphoneos/urbantest.build/Objects-normal/armv7/UA_ASIDownloadCache.o 
collect2: ld returned 1 exit status 

命令/Developer/Platforms/iPhoneOS.platform/开发/ usr/bin/gcc-4.2失败,退出代码1

Plz帮我解决了它。

回答

0

好像您正尝试使用嵌入ASIHTTPRequest库的推送通知的AirShip库。你还自己添加ASIHTTPRequest网络的东西?

如果是,链接程序在AirShip Library中找到两个具有相同名称(=同一类的两个定义)的符号,并在ASIHHTPRequest中找到一个符号。

您可以移除ASIHTTPRequest,并使用一个附带飞艇库。

+0

你好,你是对的,我想要使用飞艇但正如我芦苇他们的文档我下载的源和嵌入它的ASIHTTPRequest。我没有添加任何东西。他们的解决方案也是如此? – 2011-02-26 09:33:48

+0

你有没有尝试做一个“清洁所有目标”,并构建? – 2011-02-26 09:50:18

+0

我不知道如何“清理所有目标”?告诉我plz – 2011-02-26 09:54:56