0

I have adapted the Oomph MapKit framework for use under ARC. To do this, I created a new project in Xcode and added their sources from GitHub. I also added a small test app in the same project to test the workings of the framework. I created a target for both the framework and the test app.

All seems to be working nicely however I cannot get the imports to behave properly.

In the original source files they have (as an example from the MKAnnotation.h file):

#import <Cocoa/Cocoa.h>
#import <MapKit/MKView.h>
#import <WebKit/WebKit.h>

This generates an error in my project stating that the file MapKit/MKView.h was not found and I need to replace the import with:

#import "MKView.h"

What do I need to do make the imports with the square brackets work? I've gone through the massive amounts of settings but for the life of me cannot find a clue.

Roger
  • 4,737
  • 4
  • 43
  • 68
  • related: [What is the difference between #include and #include “filename”?](http://stackoverflow.com/questions/21593/what-is-the-difference-between-include-filename-and-include-filename) – Matthias Bauch Apr 06 '12 at 11:12

2 Answers2

0

You might need to add the framework in question to your project. Then it'll be on the search path for the "brokets" form.

Go to your project file (usually the top thing on the files listing to the left, choose your application target, usually the top thing in Targets, select Build Phases, open up "Link Binary With Libraries", and add the framework there.

Hack Saw
  • 2,741
  • 1
  • 18
  • 33
0

Why not just #import <MapKit/MapKit.h> so you have access to all of the header files contained in the MapKit framework?

Mark Adams
  • 30,776
  • 11
  • 77
  • 77
  • I tried that as one of my many tries but it still gave errors (missing files if I remember correctly). I eventually included the full project in source format into my project. Not ideal but it works. – Roger Jul 24 '12 at 23:49