ENH: add support for universal binaries

This commit is contained in:
Bill Hoffman
2006-03-24 09:15:05 -05:00
parent cec6543d0d
commit f7c1723135
9 changed files with 124 additions and 13 deletions
+14 -1
View File
@@ -231,7 +231,20 @@ int cmTryCompileCommand::CoreTryCompileCode(
// actually do the try compile now that everything is setup
int res = mf->TryCompile(sourceDirectory, binaryDirectory,
projectName, targetName, &cmakeFlags, &output);
// for the xcode generator
if(strcmp(mf->GetCMakeInstance()->GetGlobalGenerator()->GetName() ,
"Xcode") == 0)
{
int numTrys = 0;
while(output.find("/bin/sh: bad interpreter: Text file busy")
!= output.npos && numTrys < 4)
{
output = "";
res = mf->TryCompile(sourceDirectory, binaryDirectory,
projectName, targetName, &cmakeFlags, &output);
numTrys++;
}
}
if ( erroroc )
{
cmSystemTools::SetErrorOccured();