Re: building for 10.5 vs 10.6
Re: building for 10.5 vs 10.6
- Subject: Re: building for 10.5 vs 10.6
- From: Matt Neuburg <email@hidden>
- Date: Mon, 28 Jun 2010 19:25:19 -0700
- Thread-topic: building for 10.5 vs 10.6
On Mon, 28 Jun 2010 10:59:12 -0700, Bill Appleton
<email@hidden> said:
>i am currently building for 10.5 because that is our minimum user
>requirement
>
>there are some 10.6 functions i want to use, so i just check at runtime and
>use 10.6 if available
>
>but i am targeting 10.5, so i get an xcode warning in these places,
>"NSWindow may not recognize etc"
>
>so should i just target 10.6? or does that make internal libraries or
>frameworks (etc) not work on a 10.5 machine?
>
>maybe the danger is that i will accidentally use a 10.6 fx elsewhere without
>the runtime check
>
>is there a way just to suppress the warning? what do you guys do about this
>issue?
This is a FAQ, but I feel your pain, and we've all been there, so when I
suggest that you RTFM, please don't take it negatively:
http://developer.apple.com/iphone/library/documentation/DeveloperTools/Conce
ptual/cross_development/Introduction/Introduction.html
Basically it's all down to your build settings. You set the base SDK at the
latest system you want to use, and the deployment SDK at the earliest. The
problem is then the opposite of what you just said: it all just runs fine on
the 10.6 machine where you're developing, but if you refer to something that
isn't present on 10.5, you don't get any warning (and when you actually run
on 10.5, you crash). The docs explain how to use runtime testing to void
encountering crash-causing code on 10.5. It then becomes a process of
testing rigorously to make sure you got it right, and of course this is far
from easy because the machine where you're testing is different from the
machine where you're developing. Personally I find implementing backwards
compatibility *very* hard, which is why I generally just throw in the towel
and require the user to use the latest system.
And if you think this is bad, try writing for iPhone / iOS 4.0 and iPad /
iPhone OS 3.2 simultaneously. It's enough to send you screaming from the
room.
m.
--
matt neuburg, phd = email@hidden, <http://www.tidbits.com/matt/>
A fool + a tool + an autorelease pool = cool!
AppleScript: the Definitive Guide - Second Edition!
http://www.tidbits.com/matt/default.html#applescriptthings
_______________________________________________
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