FacebookSDK Corekit框架错误(FacebookSDK Corekit framework error)

我正在尝试使用FacebookSDK Sharekit / Corekit框架在我的应用程序中包含发布功能。 我将FBSDKCoreKit.frameworkFBSKShareKit.framework到Xcode项目中。

当我构建应用程序时,它在以下3个FBSDKCoreKit.framework头文件中给出了错误:

  1. FBSDKProfile.h
  2. FBSDKGraphRequest.h
  3. FBSDKAccessToken.h

这是错误的图像

在此处输入图像描述

这是给出此错误的代码。

- (instancetype)initWithTokenString:(NSString *)tokenString
                        permissions:(NSArray *)permissions
                declinedPermissions:(NSArray *)declinedPermissions
                              appID:(NSString *)appID
                             userID:(NSString *)userID
                     expirationDate:(NSDate *)expirationDate
                        refreshDate:(NSDate *)refreshDate NS_DESIGNATED_INITIALIZER;

它说Lexical or Preprocessor Issue Expected ':'

不确定为什么框架文件会出错。 请帮忙!

提前致谢


I am trying to use the FacebookSDK Sharekit/Corekit framework for including posting feature in my app. I dragged and dropped FBSDKCoreKit.framework and FBSKShareKit.framework in to Xcode project.

When I build the app it gave me error in 3 of the following FBSDKCoreKit.framework header file:

  1. FBSDKProfile.h
  2. FBSDKGraphRequest.h
  3. FBSDKAccessToken.h

Here is an image of the error

enter image description here

Here is the code that gives this error.

- (instancetype)initWithTokenString:(NSString *)tokenString
                        permissions:(NSArray *)permissions
                declinedPermissions:(NSArray *)declinedPermissions
                              appID:(NSString *)appID
                             userID:(NSString *)userID
                     expirationDate:(NSDate *)expirationDate
                        refreshDate:(NSDate *)refreshDate NS_DESIGNATED_INITIALIZER;

It says Lexical or Preprocessor Issue Expected ‘:’

Not sure why would a framework file give error. Please help!

Thanks in advance

2023-02-06 21:02

满意答案

在尝试了一切之后,解决方案是从Xcode 5升级到Xcode 7。


After trying everything, the solution was to upgrade to Xcode 7 from Xcode 5.

相关问答

更多

当我甚至没有使用Bolts时,为什么我会收到有关Bolts框架和FacebookSDK的错误?(Why am I getting an error regarding Bolts framework and FacebookSDK when I'm not even using Bolts?)

在Xcode中打开项目。 去你提取FacebookSDK的地方。 如果您使用的是Mac OSX,则应在Documents/FacebookSDK 。 抓住Bolts.framework文件并将其放入Xcode中的Frameworks文件夹中以供项目使用。 它应该现在建立。 Open the project in Xcode. Go to where you extracted the FacebookSDK. If you're using Mac OSX, it should be availa...

无法为FacebookSDK 4构建模块“FBSDKCoreKit”(Could not build module 'FBSDKCoreKit' For FacebookSDK 4)

在“生成设置”中将“允许非模块化包含在框架模块中”设置设置为YES解决了我的问题。 但不知道是否有任何问题或问题或其副作用。 它的Facebook Bug可以检查他们在这个链接中提供的解决方案。 更新1 Facebook表示,他们已经修复并将在下次更新中应用解决方案,请参阅此链接 更新2 FaceBook在版本最新版本(即4.1.0)中修复了这个链接 。 In setting the "Allow Non-modular Includes in Framework modules" setting...

Monotouch Binding和FacebookSDK(Monotouch Binding and FacebookSDK)

删除当前Facebook SDK框架的引用,并通过将其拖放到框架文件夹中再次添加Facebook SDK。 这将自动添加Facebook SDK路径。 Remove reference of current the Facebook SDK framework and add the Facebook SDK again by drag and drop it in framework folder. This will add Facebook SDK path automatically.

如何使Xcode找到文件FacebookSDK.h?(How to make Xcode find file FacebookSDK.h?)

首先,您必须从您的项目中删除您的FacebookSDK.framework。 然后再用5个步骤重新开始。 不要重新链接框架。 转到项目目标中的构建阶段。 在链接二进制库中,单击“+”按钮。 点击“添加其他...”按钮 浏览您的FacebookSDK文件夹。 一般在〜/ Documents / FacebookSDK / 打开(选择)“facebookSDK.framework”,然后打开。 而已。 First, you have to remove your FacebookSDK.framewo...

未找到“FacebookSDK / FacebookSDK.h”文件('FacebookSDK/FacebookSDK.h' file not found)

我今天遇到了同样的问题。 使用插件寄存器安装此插件目前无效(适用于iOS)。 您必须将存储库( phonegap-facebook-plugin )克隆到本地文件系统,例如$HOME/src/phonegap-facebook-plugin 。 然后安装指向该路径的插件,例如cordova plugin add $HOME/src/phonegap-facebook-plugin ... 事实证明,通过插件注册表获取FacebookSDK.framework没有正确安装。 它应该是这样的: $ l...

找不到FacebookSDK错误GADCustomEventBanner.h(FacebookSDK Error GADCustomEventBanner.h not found)

确保将FacebookSDK.Framework文件夹添加到项目中。 如果它在您的项目框架文件夹中显示为“FacebookSDK”,则说错了。 Make sure you are adding the FacebookSDK.Framework folder into your project. If it appears as "FacebookSDK" in your projects framework folder, you did it wrong.

#import 未找到IOS目标C.(#import not found IOS objective C)

如果您使用的是Cocoapods,我建议您更新您的FacebookSDK 添加这3个依赖项的最新内容: pod 'FBSDKCoreKit' pod 'FBSDKLoginKit' pod 'FBSDKShareKit' 然后从终端下载Pod Install下载框架,最后做一些更改,因为新的sdk不同。 If you are using Cocoapods i would suggest to update your FacebookSDK to the latest with adding t...

使用UnitTest时未找到FacebookSDK / FacebookSDK.h(FacebookSDK/FacebookSDK.h not found when using UnitTest)

我解决了我的问题。 我没有为MyProjectTest Target设置框架搜索路径。 在MyProject Target中设置了它,以便它只在测试中失败 I solved my problem. I didn't set the Framework Search Paths for MyProjectTest Target. In MyProject Target was set so that why it was failing only in tests

找不到选项FacebookSDK的目录(directory not found for option FacebookSDK)

当你的项目由于将项目从一个目录转移到另一个目录而无法找到你的facebookSDK框架时,会发生这种情况,试图从项目文件中删除facebook sdk并再次添加facebook sdk。 This happen when your project not able to find the your facebookSDK framework because of shifting the project from one directory to other try to delete faceb...

FacebookSDK Corekit框架错误(FacebookSDK Corekit framework error)

在尝试了一切之后,解决方案是从Xcode 5升级到Xcode 7。 After trying everything, the solution was to upgrade to Xcode 7 from Xcode 5.

相关文章

更多

IOS-Social.framework

1.使用前 需要导入Social.framework 框架 2.实例代码(新浪微博为例) - (IBA ...

AMF: ASP.NET Mobile Framework

ASP.NET移动框架(AMF)是一种最常用的平板电脑和智能手机上Web应用程序的框架,基于jQuer ...

eclipse里报:An internal error occurred during:

eclipse里报:An internal error occurred during: Buildi ...

安卓应用程序插件化开发框架 -AAP Framework

上篇博文,介绍了一种安卓开发中程序插件化的方法,想想应该可以搞的更方便些,于是花了4天时间把框架做出来 ...

安卓应用程序插件化开发框架 -AAP Framework

介绍 这个框架的初衷,是为了方便让程序模块化、插件化,将一个apk应用拆分为多个apk。 不 ...

The connection to adb is down, and a severe error has occured.

启动android模拟器时.有时会报The connection to adb is down, an ...

solr error logs org.apache.solr.common.SolrException: ERROR: [doc=17] unknown field alias

在solr中 添加新的索引词语时,报如标题所示错误,指定是插入的字段没有在solr索引字段里 可以修改 ...

Solr安装异常:SolrException: Error loading class 'solr.VelocityResponseWriter'

解决方法安装Solr过程出现错误,报异常 org.apache.solr.common.SolrExc ...

error C2668: 'M' : ambiguous call to overloaded function

以下是代码: #include<iostream>using namespace std ...

win8安装VirtualBox-4.2.18提示Installation failed!error:系统找不到指定的路径

在win8上安装VirtualBox-4.2.4-81684-Win.exe,提示Installati ...

最新问答

更多

Python / IPython奇怪的不可重现列表索引超出范围错误(Python/IPython strange non reproducible list index out of range error)

你得到IndexError的原因是你的输入文件显然不是完全用制表符分隔的。 这就是为什么当您尝试访问它时, splits[1]没有任何内容。 您的代码可以使用一些重构。 首先,你正在重复使用if -checks,这是不必要的。 这只是将cds0到7个字符,这可能不是你想要的。 我将以下内容放在一起,以演示如何重构您的代码,使其变得更加pythonic和干燥。 我无法保证它能够与您的数据集一起使用,但我希望它可以帮助您了解如何以不同的方式执行操作。 to_sort = [] # W

故事板从表格单元中延伸出来并显示其详细信息披露按钮(storyboard segue from a tablecell an its Detail Disclosure Button)

我不认为你可以链接一个特定的细节披露按钮瓦特/赛格。 我的故事板是非常程序化的B / C我使用了很多定制CGRect等。 所以我倾向于使用这样的东西: -(void)tableView:(UITableView *)tableView accessoryButtonTappedForRowWithIndexPath:(NSIndexPath *)indexPath { [self performSegueWithIdentifier:@"ViewControllerIdentifer"

我们可以将Gherkin功能文件与testcomplete集成(Can we integrate Gherkin feature files with testcomplete)

TestComplete不支持Gherkin功能文件。 但是,TestComplete具有SDK,因此可以自己为此创建扩展。 TestComplete does not support Gherkin feature files. However, TestComplete has SDK so it is possible to create an extension for this by yourself.

TrustAllCertificatesCallback被忽略(TrustAllCertificatesCallback is ignored)

我没有做过这样的事情,但看看我认为可以看出错误的例子。 试试这个代码: static class Program { static void Main() { var tcpclient = new TcpClient("remote.example.com", 443); var tcpstream = tcpclient.GetStream(); var sslstream = new SslStream(tcpstream,

返回嵌套元素的索引(Return index of nested element)

您需要获取父li元素的索引。 否则,您将获得列表项内锚点的索引,该索引始终为零。 $(this.parentNode).index(); You need to get the index of the parent li element. Otherwise you are getting the index of the anchor inside the list item, which will always be zero. $(this.parentNode).index();

在数组中重新编号元素的有效方法(Efficient way of re-numbering elements in an array)

您需要多次迭代列表,我认为没有办法解决这个问题。 毕竟,在开始更改元素(第二遍)之前,首先必须确定不同元素的数量(第一遍)。 但是请注意,由于对index的重复调用而not in列表中具有O(n),因此可能具有最多O(n ^ 2)的不同元素的数量。 或者,您可以使用dict而不是value_map的list 。 字典比列表具有更快的查找速度,因此,复杂性应该确实在O(n)的数量级上。 您可以使用(1)字典理解来确定旧值到新值的映射,以及(2)用于创建更新子项的列表理解。 value_map =

Express app定义的`static`文件夹无法正常工作(Express app defined `static` folder not working properly)

选项1 你可以改变这一行: app.use( express.static(__dirname + '/puplic')); //my public folder. 至 app.use('/oneTime', express.static(__dirname + '/puplic')); //my public folder 选项2 我假设你在公共文件夹中有一个js文件夹,然后你需要更改你的HTML代码:

使用node.js和socket.io每秒广播一次(Using node.js and socket.io to broadcast every second)

对于计时器值,请在服务器端本身每秒更新本地计时器。 每当有任何用户进来时,给他这个值以及计时器的总值。 然后客户端将根据dandavis评论在本地启动自己的计时器,但在服务器端保留一些间隔,如15或10秒,服务器将广播当前计时器值,以便客户端相应地进行同步。 简而言之,服务器将每隔10(n:你决定)秒后广播,但它将在本地每秒更新定时器变量。 每当客户端进入时,它将获得总计时器值和当前计时器值。 广播当前出价的休息功能可以以正常方式完成。 For timer value, keep updatin

如何让XMLSerializer将命名空间添加到嵌套对象中的属性?(How do I get the XMLSerializer to add namespaces to attributes in nested objects?)

IXmlSerializable也许? 注意我还添加了(对A ): [XmlElement("A", Namespace = "http://www.example.com/namespace")] public TestSoapHeaderTypeValuePair A {...} 代码如下: public class TestSoapHeaderTypeValuePair : IXmlSerializable { private string _type; private