1

Im using the FBSDK cocoapod, and the app was running perfectly fine, I have made no changes to the app or xcode settings since it was working and now when i run on a physical device i get the following error:

Error:

dyld: Library not loaded: @rpath/FBSDKCoreKit.framework/FBSDKCoreKit Referenced from: /private/var/mobile/Containers/Bundle/Application/FC27A115-3A03-462B-9980-1189DB1E6578/< app_name >.app/< app_name > Reason: Incompatible library version: < app_name > requires version 4.0.0 or later, but FBSDKCoreKit provides version 1.0.0 (lldb)

however my pod file is using FBSDK 4.4

Pod:

pod 'FBSDKCoreKit', '~> 4.4'
pod 'FBSDKLoginKit', '~> 4.4'
pod 'FBSDKShareKit', '~> 4.4'

anyone know whats going on here? I have tried new pod installs deleting the pods and reinstalling, it seems to work building to simulators

justin shores
  • 687
  • 7
  • 24

1 Answers1

1

Adding this script to my podfile and then running a pod install solved this issue for me

post_install do |installer|
    installer.pods_project.targets.each do |target|
        target.build_configurations.each do |config|
            config.build_settings['DYLIB_COMPATIBILITY_VERSION'] = ''
        end
    end
end

hope this helps someone else, I would also still be interested in any other solutions.

justin shores
  • 687
  • 7
  • 24
  • @AndreLuiz basically the script is manually disabling the compatibility version number – justin shores Sep 10 '15 at 18:37
  • I am not sure if that's the way to go. I have just removed the `DerivedData` folder and it started working again. Don't you think that disabling the compatibility version number could lead to wrong versions of the framework on which the other depends on? – alcarv Sep 10 '15 at 20:02
  • After updating to a new version of xcode, i no longer needed te script, but if you have a safer solution please post an answer so others might be able to use it. – justin shores Sep 10 '15 at 20:42
  • Show me this error `he sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.` – jose920405 Apr 28 '16 at 17:28