Use_frameworks! and podspec in the root of the repo library

I have the following dependencies in my iOS project:

source ''
platform :ios, '8.0'

pod 'CocoaLumberjack'

# other dependencies here    

pod 'MagicalRecord', :git => '', :branch => 'develop'


I am using the latest version of CocoaPods at the moment (0.37.0). pod install

gives no warnings or errors, but when I try to build, I get a linker error:

Undefined symbols for architecture armv7:
  "_OBJC_CLASS_$_DDLog", referenced from:
      objc-class-ref in MagicalRecord+ErrorHandling.o
      objc-class-ref in NSManagedObject+MagicalDataImport.o
      objc-class-ref in NSManagedObject+MagicalRecord.o
      objc-class-ref in NSManagedObjectContext+MagicalObserving.o
      objc-class-ref in NSManagedObjectContext+MagicalRecord.o
      objc-class-ref in NSManagedObjectContext+MagicalSaves.o
      objc-class-ref in NSObject+MagicalDataImport.o


Apparently, MagicalRecord

does not see CocoaLumberjack

that gives a character. The documentation says:

Sometimes you may need to use a cross-version of the Pod, a specific revision, or your own fork. If so, you can specify it with your pod declaration. It's important to note, however, that this means that the version will need to satisfy any other Pod dependencies by other Pods.

However, it does not explain exactly how these dependencies should be satisfied. Can someone explain this? Everything worked fine until I added use_frameworks!

to use a pod written in Swift.


source to share

1 answer

It looks like there is a somewhat useful workaround for this problem by tying CocoaLumberjack.framework

in the generated target Pods-MagicalRecord

in Pods.xcodeproj

. This will allow MagicalRecord to see the DDLog and therefore you should be able to compile. This is a rather fragile solution, however, as you will need to re-link the structure every time you regenerate the Pods project by running pod install





All Articles