Reputation: 346
I am developing an app that saving an url using coredata.I am defining NSManagedObjectContext,NsManagedObjectModel,NSPersistentStoreCoordinator in CoreDataRepository object class instead of AppDelegate.I am saving this url using reference of CoreDataRepository.I am getting below error.
Undefined symbols for architecture i386:
"_OBJC_CLASS_$_CoreDataRepository", referenced from:
objc-class-ref in HomeViewController.o
objc-class-ref in DashBoardUrlViewController.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Any idea about this error.Thanks.
Upvotes: 2
Views: 118
Reputation: 31016
The linker can't find your CoreDataRepository
class. Look in your target's Build Phases and add that source or library to either the compile or link phase, depending on where it's defined.
Upvotes: 2