Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to get headers into framework in Xcode?

I'm trying to build a framework for MacOS in Xcode 3. It looks like it's building everything except the Headers directory according to the layout listed in the Apple documentation. I can't find anything that tells me what settings to use to get the build process to copy the headers into Headers directory in the framework, or alternately where I have to put those files.

Any help?

Thanks.

like image 550
john146 Avatar asked Jun 13 '09 01:06

john146


People also ask

How do I open a header file in Xcode?

Your code should have a #import or #include statement to import/include the header file. Holding the Command key, click the import/include statement to view the header. Also, you can Command-click on a symbol to jump to the header file that defines it.

What is .h file in Xcode?

h, which is called the header file. The implementation section goes into MyClass. m, which is called the implementation file. The separation into two files is not inconvenient, because Xcode, expecting you to follow this convention, makes it easy to jump from editing a . h file to the corresponding .


2 Answers

The headers need to be made "public" instead of the default "project" in the framework target (select the framework target in the Files & Groups pane to list the framework files).

like image 79
Barry Wark Avatar answered Sep 28 '22 09:09

Barry Wark


You want to add the path to the framework to the framework search path, not the header search path.

like image 40
cdespinosa Avatar answered Sep 28 '22 08:09

cdespinosa