3
votes

I have added the frameworks (MapKit and CoreLocation) by selecting the Frameworks folder, right clicking, Add > Existing Frameworks.

The app builds in the Simulator (3.1.3) but fails on the Device (3.1.3) with the error:

ld: warning: in /Development/Sites/iPhone Projects/SwitchViews/MapKit.framework/MapKit, file is not of required architecture Undefined symbols:
"_OBJC_CLASS_$_MKPinAnnotationView", referenced from: __objc_classrefs__DATA@0 in NextView.o ld: symbol(s) not found collect2: ld returned 1 exit status

2

2 Answers

2
votes

It seems that I just needed to restart Xcode to get things linked up properly.

0
votes

It looks like you by accident have selected the "copy to project" checkbox when adding the framework.

Try to delete the framework from your project and add it again, making sure you have selected the default framework path, and that you don't copy it to your project.