• 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: Deprecated APIs
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Deprecated APIs


  • Subject: Re: Deprecated APIs
  • From: Jean-Daniel Dupas <email@hidden>
  • Date: Wed, 24 Feb 2010 20:48:01 +0100

Le 24 févr. 2010 à 20:36, Steve Christensen a écrit :

> On Feb 24, 2010, at 11:04 AM, Bill Bumgarner wrote:
>
>> On Feb 23, 2010, at 8:57 PM, Steve Christensen wrote:
>>
>>>> That code uses blocks, though, which implies that it will be compiled using a later version of Objective-C. Will that code really run on older versions of OS X?
>>>
>>> The compile-time conditional assumes that you're building against the 10.6 SDK (or later). Obviously if you're going to support both cases, you'll need to use a compiler configuration that is compatible with all the OS versions you plan to support.
>>
>> There are symbols *sometimes* emitted by compilation of blocks that won't be available on prior releases of Mac OS X and, thus, will cause a dyld error on launch on those platforms.
>>
>> Be careful.
>
> Is this the case even if you're weak-linking against 10.6, i.e., you're setting the deployment target to 10.4? And is this a blocks-specific issue? I don't recall ever having problems with other cases when I wanted to call a newer API method conditional on the OS version.



Unfortunately, the compiler is not smart enough to generate weak symbols, so no way to use weak linking here. The only solution is to create an external bundle with code using block and load it on Snow Leopard (just like when you want to use a new class, as class does not supports weak linking on Mac OS X yet).


-- Jean-Daniel



_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Deprecated APIs (From: charisse napeÿfffff1as <email@hidden>)
 >Re: Deprecated APIs (From: Steve Christensen <email@hidden>)
 >Re: Deprecated APIs (From: Charles Srstka <email@hidden>)
 >Re: Deprecated APIs (From: Steve Christensen <email@hidden>)
 >Re: Deprecated APIs (From: Bill Bumgarner <email@hidden>)
 >Re: Deprecated APIs (From: Steve Christensen <email@hidden>)

  • Prev by Date: Re: Odd NSString behavior
  • Next by Date: Re: Stuck on NSTreeController bindings
  • Previous by thread: Re: Deprecated APIs
  • Next by thread: Re: Deprecated APIs
  • Index(es):
    • Date
    • Thread