2The Compiler

The compiler is the fundamental tool in your programming arsenal. No matter what editor you use for source code and no matter if you build your programs with Xcode or make, the compiler is involved. Apple ships the GNU Compiler Collection with the developer tools. You can invoke the compiler with the gcc command, but you can also use the cc command.

The Mac OS X 10.4 and 10.5 development tools include gcc versions 3.3 and 4.0. You can use the older compiler if you have code that will not compile with the newer compiler or if you need to support versions of Mac OS X prior to version 10.3.9. gcc 4.2 is the default for 10.6 and is incompatible with the 10.4 (and earlier) SDKs. Also, gcc 4.2 is the minimum compiler you can use with ...

Get Advanced Mac OS X Programming: The Big Nerd Ranch Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.