• 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: Modifying dyld behavior for framework
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Modifying dyld behavior for framework


  • Subject: Re: Modifying dyld behavior for framework
  • From: Stephan Burlot <email@hidden>
  • Date: Wed, 11 Dec 2002 00:30:25 +0100

On 10.12.2002 2:40, Mike Ferris <email@hidden> wrote:

>>> Question 2: how can I detect at runtime if the framework is in
>>> /Library/Frameworks or (~/Library/Frameworks) and display a meaningful
>>> message before dying?
>>>
> You really can't in any simple way.

Since I've not been able to include (and use) a local copy of the framework
in my application bundle, what I did to prevent the violent death of my app
was to remove the framework from the target of my project and set these
options in the linker:
-undefined suppress -flat_namespace

And use
NSBundle *myBundle=[NSBundle bundleWithPath:[NSString
stringWithFormat:@"%@/%@",@"/Library/Frameworks",bundleName]];

Then I use NSIsSymbolNameDefined to check if the bundle was found, loaded
and ready.

If not, I can display a meaningful message to the user.

Is that simple!?

Thanks for your help,

Stephan
_______________________________________________
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: 
 >Re: Modifying dyld behavior for framework (From: Mike Ferris <email@hidden>)

  • Prev by Date: Re: Initializing NSOpenGLViews
  • Next by Date: Re: buttonType in NSButton
  • Previous by thread: Re: Modifying dyld behavior for framework
  • Next by thread: Re: NSUndoManager - clearing a single 'redo' - Now->doesn't respond to removeAllActionsWithTarget
  • Index(es):
    • Date
    • Thread