• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: XCode and frameworks
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: XCode and frameworks


  • Subject: Re: XCode and frameworks
  • From: Michael Rothwell <email@hidden>
  • Date: Sun, 18 Jan 2004 15:27:41 -0500

This and a few other things seem to have done the trick (thanks!).

The other things include:
* select "skip install"
* set up the INSTALL_PATH (as below)
* set up the "public headers" location
* mark headers that need to be public, as public
* compile the framework with the "deployment" style so the headers get copied (this was major contributor to my frustration. :)
* set up a "copy files" build phase to copy in resources (such as frameworks, e.g., libxml)
* include the framework in the application project.

Thanks for all the replies. It would be cool if XCode had an "Embedded Framework" project type that did the above, and created a public "FRAMEWORK.h" file.

-M


On Jan 18, 2004, at 12:55 PM, Devin Lane wrote:

Basically, you just make a new framework project (Cocoa?) and add classes. Then compile it, and you will have a framework file. Make sure your framework project has a main header file, which includes everything. When you want to use the framework in another project, include the header by using #import "Myframework/myheader.h"

If you want to store your framework in the frameworks folder in your application bundle, you must add this: to your target settings (double click the framework target)

INSTALL_PATH = @executable_path/../Frameworks

That should do it, hope it works


-- Devin Lane, Cocoa Programmer,Benson H.S. Newspaper Layout Designer,
email: email@hidden
On Jan 18, 2004, at 9:15 AM, Michael Rothwell wrote:

I'm trying to separate out some of my project's code into a (private) framework. XCode is making this an extremely frustrating and difficult exercise. I'm surprised at how arcane it is... come on, Apple!

Does anyone have a tutorial they would like to share? I would really appreciate it.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >XCode and frameworks (From: Michael Rothwell <email@hidden>)

  • Prev by Date: Re: creating plist, reading too
  • Next by Date: speed of alloc/init for NSNumber
  • Previous by thread: Re: XCode and frameworks
  • Next by thread: Re: XCode and frameworks
  • Index(es):
    • Date
    • Thread