Reputation: 401
I'm trying to build a static library but i get compile-time errors such as: Unknown type name UIImage
or Unknown type name CGSize
.
I have added both UIKit and CoreGraphics frameworks to Link Binary With Libraries
.
What am I doing wrong ??
Upvotes: 3
Views: 3618
Reputation: 78835
The libraries are relevant during the linking phase only. For the compilation, the import
statements are relevant.
Most likely you are missing:
#import <UIKit/UIKit.h>
Upvotes: 0
Reputation: 34912
If it's compile time errors then it's nothing to do with the libraries you're linking against. This error sounds very much like you haven't included the UIKit headers. Make sure that you have #import <UIKit/UIKit.h>
in the files that you're using UIImage
and CGSize
in.
Upvotes: 11