I recently upgraded to OS X 10.8 Mountain Lion and Xcode 4.4, and quickly found out that the 10.6 SDK was removed from Xcode. Unfortunately, Android requires it to build and gives an error like this when running make:
build/core/combo/HOST_darwin-x86.mk:62: *****************************************************
build/core/combo/HOST_darwin-x86.mk:63: * Can not find SDK 10.6 at /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.6.sdk
build/core/combo/HOST_darwin-x86.mk:65: * If you wish to build using higher version of SDK,
build/core/combo/HOST_darwin-x86.mk:66: * try setting BUILD_MAC_SDK_EXPERIMENTAL=1 before
build/core/combo/HOST_darwin-x86.mk:67: * rerunning this command
build/core/combo/HOST_darwin-x86.mk:69: *****************************************************
build/core/combo/HOST_darwin-x86.mk:70: *** Stop.. Stop.
To work around it, run this from Terminal:
export BUILD_MAC_SDK_EXPERIMENTAL=1
Also, I got a compile failure after running ‘make’ under Mountain Lion:
************************************************************
You are attempting to build with the incorrect version
of java.
Your version is: java version “1.7.0_07”.
The correct version is: Java SE 1.6.
Please follow the machine setup instructions at
https://source.android.com/source/download.html
************************************************************
build/core/main.mk:141: *** stop. Stop.
Java 7 became the default JDK after the upgrade. To switch back to Java 6, run this from Terminal:
export JAVA_HOME=`/usr/libexec/java_home -v 1.6`