Use 10.5 SDK for building NativeHost if available, otherwise use latest Mac OS X SDK.

Reviewed by me.
This commit is contained in:
Francisco Ryan Tolmasky I committed 2011-03-10 12:33:35 -04:00
1 parent 8eb8b7711d
commit acf7ef3a96
2 files changed
+19 -12

No files matched your search

+13 -10
View File
@@ -9,17 +9,20 @@ task ("build", function()
{
if (executableExists("xcodebuild"))
{
if (OS.popen("xcodebuild -version").stdout.read().match("Xcode 4.0"))
stream.print("\0red(Building NativeHost was skipped due to your Xcode 4.0 pre-release not including the Mac OS X 10.5 SDK.\0)");
var args = "-alltargets -configuration Release";
if (FILE.exists(FILE.join("/", "Developer", "SDKs", "MacOSX10.5.sdk")))
args = "-sdk macosx10.5 " + args;
else
{
if (OS.system("xcodebuild -alltargets -configuration Release"))
OS.exit(1);
rm_rf(FILE.join($BUILD_CJS_CAPPUCCINO, "support", "NativeHost.app"));
FILE.mkdirs(FILE.join($BUILD_CJS_CAPPUCCINO, "support"))
cp_r(FILE.join("build", "Release", "NativeHost.app"), FILE.join($BUILD_CJS_CAPPUCCINO, "support", "NativeHost.app"));
}
args = "-sdk macosx " + args;
if (OS.system("xcodebuild " + args))
OS.exit(1);
rm_rf(FILE.join($BUILD_CJS_CAPPUCCINO, "support", "NativeHost.app"));
FILE.mkdirs(FILE.join($BUILD_CJS_CAPPUCCINO, "support"))
cp_r(FILE.join("build", "Release", "NativeHost.app"), FILE.join($BUILD_CJS_CAPPUCCINO, "support", "NativeHost.app"));
}
else
{
@@ -254,7 +254,11 @@
isa = PBXProject;
buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "NativeHost" */;
compatibilityVersion = "Xcode 3.1";
developmentRegion = English;
hasScannedForEncodings = 1;
knownRegions = (
en,
);
mainGroup = 29B97314FDCFA39411CA2CEA /* NativeHost */;
projectDirPath = "";
projectRoot = "";
@@ -373,7 +377,7 @@
GCC_WARN_UNUSED_VARIABLE = YES;
ONLY_ACTIVE_ARCH = YES;
PREBINDING = NO;
SDKROOT = macosx10.5;
SDKROOT = macosx;
};
name = Debug;
};
@@ -385,7 +389,7 @@
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
PREBINDING = NO;
SDKROOT = macosx10.5;
SDKROOT = macosx;
};
name = Release;
};