Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/ios/111.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ios 使用facebook和parse sdk编译错误_Ios_Facebook_Parse Platform - Fatal编程技术网

Ios 使用facebook和parse sdk编译错误

Ios 使用facebook和parse sdk编译错误,ios,facebook,parse-platform,Ios,Facebook,Parse Platform,我在Parse SDK 1.7.5和facebook SDK 4.3.0中遇到以下编译错误 “\FBTokenInformationExpirationDateKey”,引用自: “\FBTokenInformationTokenKey”,引用自: “\FBTokenInformationUserFBIDKey”,引用自: “_OBJC_CLASS_$_FBAppCall”,引用自: “_OBJC_CLASS_$_FBRequest”,引用自: “_OBJC_CLASS_$_FBSession”

我在Parse SDK 1.7.5和facebook SDK 4.3.0中遇到以下编译错误

“\FBTokenInformationExpirationDateKey”,引用自:

“\FBTokenInformationTokenKey”,引用自:

“\FBTokenInformationUserFBIDKey”,引用自:

“_OBJC_CLASS_$_FBAppCall”,引用自:

“_OBJC_CLASS_$_FBRequest”,引用自:

“_OBJC_CLASS_$_FBSession”,引用自:

“_OBJC_CLASS_$_FBSessionTokenCachingStrategy”,引用自:

“对象元类”引用自:

叮当声:错误:链接器命令失败,退出代码为1(使用-v查看 调用)

以下是我的应用程序委托:

import UIKit
import Bolts
import Parse

@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {

var window: UIWindow?


func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool {
    // Override point for customization after application launch.

    Parse.enableLocalDatastore()

    // Initialize Parse.
    Parse.setApplicationId("Lqy9Q5hchqnXNVY56hnyTwabrij4R2FDP47FsLZ3",
        clientKey: "h1BXeaoBgytENrnNfxok1ghlTWiEadM5vX5K4bqU")

    PFFacebookUtils.initializeFacebookWithApplicationLaunchOptions(launchOptions)

    // [Optional] Track statistics around application opens.
    PFAnalytics.trackAppOpenedWithLaunchOptions(launchOptions)

    let userNotificationTypes = (UIUserNotificationType.Alert |  UIUserNotificationType.Badge |  UIUserNotificationType.Sound);

    let settings = UIUserNotificationSettings(forTypes: userNotificationTypes, categories: nil)
    application.registerUserNotificationSettings(settings)
    application.registerForRemoteNotifications()

    return FBSDKApplicationDelegate.sharedInstance().application(application, didFinishLaunchingWithOptions: launchOptions)
}

func applicationWillResignActive(application: UIApplication) {
    // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
    // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
}

func applicationDidEnterBackground(application: UIApplication) {
    // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
    // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
}

func applicationWillEnterForeground(application: UIApplication) {
    // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
}

func applicationDidBecomeActive(application: UIApplication) {
    // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
    FBSDKAppEvents.activateApp()
}

func applicationWillTerminate(application: UIApplication) {
    // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
}

func application(application: UIApplication, didRegisterForRemoteNotificationsWithDeviceToken deviceToken: NSData) {
    // Store the deviceToken in the current Installation and save it to Parse
    let installation = PFInstallation.currentInstallation()
    installation.setDeviceTokenFromData(deviceToken)
    installation.saveInBackground()
}

func application(application: UIApplication,
    openURL url: NSURL,
    sourceApplication: String?,
    annotation: AnyObject?) -> Bool {
        return FBSDKApplicationDelegate.sharedInstance().application(application,
            openURL: url,
            sourceApplication: sourceApplication,
            annotation: annotation)
}



}
在代码中添加PFFacebookUtils.initializeFacebookWithApplicationLaunchOptions(启动选项)之前没有错误

更详细的错误信息:架构x86_64的未定义符号: “\FBTokenInformationExpirationDateKey”,引用自: -ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)中的[PFFacebookTokenCachingStrategy cacheTokenInformation:] -ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)中的[PFFacebookTokenCachingStrategy expirationDate] -ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)中的[PFFacebookTokenCachingStrategy setExpirationDate:] “\FBTokenInformationTokenKey”,引用自: -ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)中的[PFFacebookTokenCachingStrategy accessToken] -ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)中的[PFFacebookTokenCachingStrategy setAccessToken:] “\FBTokenInformationUserFBIDKey”,引用自: -ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)中的[PFFacebookTokenCachingStrategy facebookId] -ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)中的[PFFacebookTokenCachingStrategy setFacebookId:] “_OBJC_CLASS_$_FBAppCall”,引用自: ParseFacebookUtils(PFFacebookAuthenticationProvider.o)中的objc类引用
“_OBJC_CLASS_$_FBRequest”,引用自: ParseFacebookUtils(PFFacebookAuthenticationProvider.o)中的objc类引用
“_OBJC_CLASS_$_FBSession”,引用自: ParseFacebookUtils(PFFacebookAuthenticationProvider.o)中的objc类引用
“_OBJC_CLASS_$_FBSessionTokenCachingStrategy”,引用自: _ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)中的OBJC_CLASS_$\u PFFacebookTokenCachingStrategy
“对象元类”引用自: _ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)中的OBJC\u元类\u$\ u PFFacebookTokenCachingStrategy ld:符号不可用 找到架构x86_64的clang:错误:链接器命令失败,错误为 退出代码1(使用-v查看调用)


检查这些SDK所需的库和框架,并将其包含在您的项目中。我非常确定所有需要的框架都包含在内。您是否添加了必要的其他链接器标志?e、 例如,
-ObjC
?和(非)任何外部库的递归路径?另外,您能检查一下这个解析SDK是否与您正在使用的facebook SDK兼容吗?我试图在链接器标志中添加-ObjC,它生成了更多错误我通过删除链接库中的ParseFacebookUtils解决了这个问题,只保留ParseFaceBookUtilsv4检查这些SDK所需的库和框架,并将其包含在您的项目中。我非常确定所需的所有框架都包含在内您是否添加了其他必要的链接器标志?e、 例如,
-ObjC
?和(非)任何外部库的递归路径?另外,请检查此Parse SDK是否与您正在使用的facebook SDK兼容?我尝试将-ObjC添加到链接器标志中,它生成了更多错误我通过删除链接库中的ParseFacebookUtils并仅保留ParseFacebookUtilsV4解决了此问题