Re: MAC_OS_X_VERSION_MAX_ALLOWED?



In article <1h99rp5.194lobb17iq2zyN%burt@xxxxxxxxxxxxxxxxx>,
burt@xxxxxxxxxxxxxxxxx (Burt Johnson) wrote:

> Just starting OS X development for the first time. I wrote Mac code in
> the 90's, but never had a chance for a OS X project till now (been on
> the Dark Side with VC++ the past few years)
>
> I was handed a project started by another programmer that had to bail,
> and am trying to get it to build. I have gone through the first few
> chapters of "Cocoa Programming For Mac OS X" by Hillegass to get the
> basic foundation.
>
> I try to build this inherited code, and get an error in my xx_prefix.pch
> saying
>
> MAC_OS_X_VERSION_MAX_ALLOWED must be >= MAC_OS_X_VERSION_MIN REQUIRED
>
> Doing a search on the project, I can't see where either is defined
> though. I _do_ find the check in foundation.h, which is imported in
> cocco.h, which is imported in xx_prefix.pch.
>
> Where do I find these constants?
>
> While we are at it, any other hints in general to getting someone else's
> code running on my machine? Any common gotcha's when moving between
> developer's machines that I should know about?

Create a New project of a similar type with the correct name, using
XCode's New Project menu command, then, in the Finder, copy over your
sources into the new project's folder, then, with XCode over, drag the
sources onto the project window. That will at least set up your
precompiled prefix and general build environment.

The correct name, because you'd have to go to many arcane dialog boxes
and config files to change it later.

Command-clicking on MAC_OS_X_VERSION_MAX_ALLOWED or on
MAC_OS_X_VERSION_MIN_REQUIRED shows that they are defined in
/usr/include/AvailabilityMacros.h

or:

/Developer/SDKs/MacOSX10.4.0.sdk/usr/include/AvailabilityMacros.h

if you are using one of the /Developer/SDKs to specify a specific
software version.

Biggest gotcha is non-system libraries that you forget to move, or add
to your project, so that the code is actually linked in. Also, if you
are using Cocoa, and you have ZeroLink turned on, your program will
happily run with some missing libraries, with messages to non-existent
objects just returning nil.
.



Relevant Pages

  • Universal PIC switchmode status report
    ... output voltage setpoint ... I looked and thought: 'Why not use a transformer, 1:1', (and actually the SEPIC design solves ... SO, after reading that remark, went back, soldered it out, put the PIC in the programmer, it already has ... the RS232 interface, programmed it, 100% OK first time, ...
    (sci.electronics.design)
  • Re: Migrating a system incrementally. Was: Re: Static vs. Dynamic typing (big advantage or not)---W
    ... How many times have you gotten it right the first time. ... professional programmer I have yet to get it right the first time. ... But IME the cost of the static typing outweighs that ... dynamically typed language build time is zero. ...
    (comp.object)
  • Re: Migrating a system incrementally. Was: Re: Static vs. Dynamic typing (big advantage or not)---W
    ... How many times have you gotten it right the first time. ... professional programmer I have yet to get it right the first time. ... But IME the cost of the static typing outweighs that ... dynamically typed language build time is zero. ...
    (comp.programming)
  • Memory Leak Problem
    ... Just to start off, this is my first time on this forum, so I aplogize ... Before I get into my problem, I'm not a programmer, I'm a stats ... And each iteration I generated about 700000 random numbers. ...
    (comp.lang.fortran)
  • CLR bug?
    ... as it was the first time ever I had expericed a ... compilation/i.l execution in .net. ... As a former c++ programmer I had learned ... foreach (ListViewItem lvi in this.listViewToDoList.Items) ...
    (microsoft.public.dotnet.languages.csharp)