• 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: DYLIB/LIB/FRAMEWORKS for iPhone ?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: DYLIB/LIB/FRAMEWORKS for iPhone ?


  • Subject: Re: DYLIB/LIB/FRAMEWORKS for iPhone ?
  • From: Greg Guerin <email@hidden>
  • Date: Fri, 16 May 2008 15:32:21 -0700

marc hoffman wrote:

>i hope you can excuse the probably noob-ish question but - when going via
>this first approach, how would you handle #import<MyFrameworkname \foo.h>
>directives that occur in the "framework" code that you're statically
>adding to your project? would you need to ifdef them all a la
>
>#ifdef IPHONE
>#import "foo.h"
>#else
>#import <MyFrameworkname\foo.h>
>#endif
>
>or is there some way to teach the monolithic project about
><MyFrameworkname\*.h>? i've found that (as expected), simply adding code
>for an existing framework i'm working on to an application project, it
>wont know how to handle the includes, and depending on the number of
>files, manually adjusting/ifdefing all imports seems excessive/not
>feasible...

First, you should have /, not \, in your imports.

Second, you seem to think that frameworks can only represent dylibs.  This
is incorrect.  A framework can represent a static library, too.  So make a
static framework with headers and then you should be able to use:
  #import <MyFrameworkname/foo.h>
in all your source.

It really comes down to how you organize your libraries.

If you organize them uniformly as frameworks, static or dynamic, then the
source should be able to refer to them uniformly using the framework-import
idiom.  If you don't, then you have to use source-level ad-hockery like
ifdefs, or include-path ad-hockery in your build settings.


Google for keywords:
  framework programming guide site:apple.com

  -- GG


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: DYLIB/LIB/FRAMEWORKS for iPhone ?
      • From: marc hoffman <email@hidden>
  • Prev by Date: Re: DYLIB/LIB/FRAMEWORKS for iPhone ?
  • Next by Date: Books?
  • Previous by thread: Re: DYLIB/LIB/FRAMEWORKS for iPhone ?
  • Next by thread: Re: DYLIB/LIB/FRAMEWORKS for iPhone ?
  • Index(es):
    • Date
    • Thread