解析 iOS:尝试运行应用程序时出错 [英] Parse for iOS: Errors when trying to run the app
问题描述
我一直在使用 Parse SDK,并遵循了快速步骤指南.当我尝试运行时,出现这 8 个错误.关于为什么的任何想法?它看起来与我没有使用的 Parse 的 Facebook 部分有关.
I've been working with the Parse SDK and I followed the quickstep guide. When I try to run, I get these 8 errors. Any ideas as to why? It looks like something to do with the Facebook part of Parse which I'm not using.
Undefined symbols for architecture armv7:
"_FBTokenInformationTokenKey", referenced from:
-[PFFacebookTokenCachingStrategy accessToken] in Parse(PFFacebookTokenCachingStrategy.o)
-[PFFacebookTokenCachingStrategy setAccessToken:] in Parse(PFFacebookTokenCachingStrategy.o)
"_FBTokenInformationExpirationDateKey", referenced from:
-[PFFacebookTokenCachingStrategy cacheTokenInformation:] in Parse(PFFacebookTokenCachingStrategy.o)
-[PFFacebookTokenCachingStrategy expirationDate] in Parse(PFFacebookTokenCachingStrategy.o)
-[PFFacebookTokenCachingStrategy setExpirationDate:] in Parse(PFFacebookTokenCachingStrategy.o)
"_OBJC_METACLASS_$_FBSessionTokenCachingStrategy", referenced from:
_OBJC_METACLASS_$_PFFacebookTokenCachingStrategy in Parse(PFFacebookTokenCachingStrategy.o)
"_OBJC_CLASS_$_FBSessionTokenCachingStrategy", referenced from:
_OBJC_CLASS_$_PFFacebookTokenCachingStrategy in Parse(PFFacebookTokenCachingStrategy.o)
"_FBTokenInformationUserFBIDKey", referenced from:
-[PFFacebookTokenCachingStrategy facebookId] in Parse(PFFacebookTokenCachingStrategy.o)
-[PFFacebookTokenCachingStrategy setFacebookId:] in Parse(PFFacebookTokenCachingStrategy.o)
"_OBJC_CLASS_$_FBRequest", referenced from:
objc-class-ref in Parse(PFFacebookAuthenticationProvider.o)
"_OBJC_CLASS_$_FBSession", referenced from:
objc-class-ref in Parse(PFFacebookAuthenticationProvider.o)
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
推荐答案
这是与 Parse iOS 1.1.33 版本相关的某种错误,因为很多人都看到了同样的错误——包括我自己.
This is some sort of bug associated with the Parse iOS 1.1.33 release as multiple people are seeing the same errors- myself included.
有几种解决方法-
如果您不使用需要 -ObjC 链接器标志的库,您可以从项目中删除 -ObjC:
If you're not using a library which requires the -ObjC linker flag, you can remove -ObjC from your project:
构建设置 > 其他链接器标志 > 删除 -ObjC
Build Settings > Other Linker Flags > remove -ObjC
或者如果您正在使用需要该标志的库,您可以添加 Facebook SDK.
or if you are using a library which requires that flag, you can add the Facebook SDK.
这两个选项都会消除错误.希望他们能解决这个问题,因为我的应用中不需要 Facebook SDK.
Both options will eliminate the errors. Hopefully they fix this as I have no need for the Facebook SDK in my app.
关注这里的讨论:
https://parse.com/questions/cocoapods-incompatibility
这篇关于解析 iOS:尝试运行应用程序时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!