Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

dyld: Library not loaded: @rpath/SwiftyJSON.framework/SwiftyJSON

This is a sequel to question : dyld: Library not loaded: @rpath/SwiftyJSON.framework/SwiftyJSON

After rebuilding the project from scratch (new project, new podfile, new files but in each file copy-paste the source code from the original project) the app compiles now and runs perfectly on every simulator! No Errors.

However running on an iPhone 4S or on a iPad 2 I get the same error BUT different reason :

dyld: Library not loaded: @rpath/SwiftyJSON.framework/SwiftyJSON
  Referenced from: /private/var/mobile/Containers/Bundle/Application/EFC891F9-C22B-4503-8F11-F30769183439/Demo Mobile.app/Demo Mobile
  Reason: Incompatible library version: Demo Mobile requires version 2.0.0 or later, but SwiftyJSON provides version 1.0.0

(lldb)

My frameworks in my Podfile :

pod 'Alamofire' , '~> 1.3'
pod 'MBProgressHUD', '~> 0.9.0'
pod 'SwiftyJSON', '~> 2.2.1'
pod 'SQLite.swift', git: 'https://github.com/stephencelis/SQLite.swift.git'
like image 632
Glenn Avatar asked Aug 05 '15 15:08

Glenn


2 Answers

I solved the problem by removing SwiftyJSON from the cocoa pods and adding the file manually to the project

like image 120
Glenn Avatar answered Oct 08 '22 10:10

Glenn


I had the same problem when I update the pod file yesterday. To solve the issue goto Xcode window -> projects -> "Select your project" and Delete the Derived Data.

like image 2
Ankahathara Avatar answered Oct 08 '22 10:10

Ankahathara