在swift iOS应用程序中使用FBSDK的问题 [英] issue using FBSDK in swift iOS application

查看:363
本文介绍了在swift iOS应用程序中使用FBSDK的问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用FBSDK在swift中编写iOS 8应用程序,以允许用户登录我的应用程序。到目前为止,我已经使用Briftging-Header.h文件在swift中使用FBSDK v3.25成功实现了登录功能,并根据FB开发人员网站上给出的说明更新了info.plist。现在我想创建一个应用程序(或更新我当前的应用程序)到FBSDK v4.01但是当我按照将它集成到我的应用程序的相同过程时,我得到以下错误:

I am coding an iOS 8 app in swift using the FBSDK to allow users to log in to my app. So far I have successfully implemented the login feature using the FBSDK v3.25 in swift using a Bridging-Header.h file and updating the info.plist accordingly to the instructions given on the FB developers website. Now I want to make an app (or update my current one) to FBSDK v4.01 but when I follow the same process of integrating it into my app I get the following errors:

-> FBSDKAppLinkResolver.h

    /Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FacebookSDK/FBSDKCoreKit.framework/Headers/FBSDKAppLinkResolver.h:21:9: Include of non-modular header inside framework module 'FBSDKCoreKit.FBSDKAppLinkResolver'

    /Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FacebookSDK/FBSDKCoreKit.framework/Headers/FBSDKAppLinkResolver.h:21:9: Include of non-modular header inside framework module 'FBSDKCoreKit.FBSDKAppLinkResolver'

-> Bridging-Header.h

    /Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FBLoginUsingSDK4/Bridging-Header.h:12:9: Could not build module 'FBSDKCoreKit'

    /Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FBLoginUsingSDK4/Bridging-Header.h:13:9: Could not build module 'FBSDKLoginKit'

    /Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FBLoginUsingSDK4/Bridging-Header.h:12:9: Could not build module 'FBSDKCoreKit'

->FBSDKLoginButton.h

    /Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FacebookSDK/FBSDKLoginKit.framework/Headers/FBSDKLoginButton.h:21:9: Could not build module 'FBSDKCoreKit'

    Failed to import bridging header '/Users/danieloram/Desktop/IOS/SWIFT/FBLoginUsingSDK4/FBLoginUsingSDK4/Bridging-Header.h'

最明显要注意的是最后一个错误,它表示无法找到桥接标题,但它与它的位置相同当我使用FBSDK 3.25时?

The most obvious thing to note is the last error which says the bridging header cannot be found but it is in the same place as it was for when I was using FBSDK 3.25?

此外,FaceBook开发人员网站上的所有文档和教程都是obj-c,因此找到解决方案是一个非常令人沮丧的过程。任何人都可以帮助诊断我做错了什么吗?任何帮助表示赞赏!

Also, all of the documentation and tutorials on the FaceBook developers website are all in obj-c so finding a solution has been a very frustrating process. Can anyone help diagnose what i am doing wrong? Any help is appreciated!

更新

目前我已设法编译我的应用程序按照Facebook开发人员门户网站上的说明操作,通过在终端中运行以下命令从FBSDK中删除所有模块

for the time being I have managed to compile my app by following the instructions in the Facebook developers portal and removing all modules from the FBSDK by running the following in terminal

rm -r ~/Documents/FacebookSDK/FBSDKCoreKit.framework/Modules/
rm -r ~/Documents/FacebookSDK/FBSDKLoginKit.framework/Modules/
rm -r ~/Documents/FacebookSDK/FBSDKShareKit.framework/Modules/

这是我的解决方法,直到发布了正确的修复程序。

this is my workaround until a proper fix is released.

推荐答案

这是一个错误,Facebook目前正在将此分配给相应的团队。

This is a bug and Facebook is currently "assigning this to the appropriate team".

要获取此更新问题请点击此链接:

To get updates to this issue follow this link:

HTTPS:/ /developers.facebook.com/bugs/362995353893156/

并点击订阅。

一些人们有四并使用此链接上的答案成功(没有一个对我有用):

Some people have found success using the answers on this link (none have worked for me):

FBSDKCoreKit的Facebook iOS8 SDK构建模块错误

这篇关于在swift iOS应用程序中使用FBSDK的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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