解决方法
我使用以下导入来访问Facebook SDK:
#import <FacebookSDK/FacebookSDK.h>
您的环境似乎没有Facebook框架.下载那个here.
更新
我找到了官方Facebook的答案.显然,这些是不推荐使用的标题,仍可用于向后兼容性.
请注意,在底部,如果在完成以下步骤后Xcode在识别导入时出现问题,请重新启动XCode.
Add the headers by dragging the DeprecatedHeaders folder from the@H_403_2@ FacebookSDK.framework/Versions/A/DeprecatedHeaders folder into the@H_403_2@ Frameworks section of your Project Navigator.
Choose ‘Create groups for any added folders’ and deselect ‘Copy items@H_403_2@ into destination group’s folder (if needed)’. This adds the headers as@H_403_2@ a reference.
Now,open up your app delegate header file and replace the Facebook@H_403_2@ framework import with the Facebook header import.
Change:
#import <FacebookSDK/FacebookSDK.h>
To:
#import "Facebook.h"
This allows you to make call to the FBDialog classes. The Facebook.h@H_403_2@ header includes the@H_403_2@ header files.
Note: If you have any problems with Xcode recognizing the Facebook.h@H_403_2@ file,just close and reopen your Xcode project.