Re: Building for 10.3 target using X-Code 2.1
Re: Building for 10.3 target using X-Code 2.1
- Subject: Re: Building for 10.3 target using X-Code 2.1
- From: Greg Guerin <email@hidden>
- Date: Tue, 2 May 2006 10:40:30 -0700
John Draper wrote:
>I'm using X-Code 2.1 and building for a 10.3 target. If I were to
>accidentely use a 10.4
>object, wouldn't the compiler tell me about it?
One thing isn't clear to me: which OS version are you running Xcode 2.1 on?
I'm assuming 10.4, but it's a guess because I don't recall Xcode 2.1's min
OS rqmt.
>> GUI031506.LinkFileList" -framework Cocoa -framework WebKit -framework
>> CoreData -framework Foundation -framework AppKit -arch ppc
Unless I'm mistaken, CoreData is a 10.4-only framework. Ref:
<http://developer.apple.com/macosx/coredata.html>
"Core Data, new in Tiger, ..."
>Why is the linker trying to link in these 10.4 objects when I explicitly
>specify I want the target to run on 10.3?
Which setting(s) do you use to specify 10.3 as the target?
If one of them isn't SDKROOT, then it's not compiling against 10.3 SDK.
>We've taken a lot of care not to use 10.4 stuff, but how can I be sure
>that the newer
>Apple API's which were implemented in 10.3 aren't going to call 10.4
>objects?
As long as your code is compiled and linked only against the 10.3 SDK, then
it's impossible to refer to a 10.4 object, because no such objects exist in
the 10.3 SDK. That is, the 10.3 SDK is self-consistent.
However, if your project settings happen to have a reference to the current
OS's frameworks, and that OS is 10.4, then 10.4 information will "leak
through" into what should be a 10.3-only target.
One possible leakage is any project setting that holds a pathname, like a
Search Headers setting, where the pathname is absolute rather than relative
to SDKROOT. I had some of those when I upgraded some older projects to
Xcode 2.2.1, which I changed by prepending $(SDKROOT) to the pathname, or
reconfiguring the setting to not need an SDKROOT-relative reference at all.
SDKROOT is set in the project's top-level Info window. I'm not sure if
Xcode 2.1 has that or not.
>How can I identify which objects these are. The classes are specified,
>and I'm not knowingly
>using ANY of these, but something is. How can I find out which ones
>they are?
Use the 'nm' command to list the symbol names in all the compiled but
unlinked object-files, and grep nm's output for CIColor or other patterns.
You can also use the 'find' command to walk a directory tree and apply the
nm|grep to objects it finds.
If you suspect a framework is referencing CIColor and others, then apply
'nm' to the framework's object files.
-- 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