문제

Am I supposed to adjust FRAMEWORK_SEARCH_PATHS or HEADER_SEARCH_PATHS when I add custom frameworks to the project?

I have MainProject.xcodeproject that links SomeFramework.framework that's simply dragged from "Products" in SomeFramework.xcodeproject to "Link with Binary Libraries" build phase in main project.

Framework contains all required headers in its Headers directory. However, in my project I can't simply use:

#import <SomeFramework.h> // I'm pretty sure this file exists

to include this header. Build fails "No such file or directory". Compiler flags include -F…/SomeFramework/build/Release and that directory contains framework with Headers directory symlink in it.

(BTW: this is for Mac OS X. I don't care about iPhone.)

도움이 되었습니까?

해결책

Just adding the path to the directory containing the framework to FRAMEWORK_SEARCH_PATHS will work. Unless it's a typo, your problem seems to be

#import <SomeFramework.h>

which should be

#import <SomeFramework/SomeFramework.h>
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top