提交 ab25ce87 编写于 作者: J Jonathan Chambers

Revert "Remove osx x86 builds."

This reverts commit 2b4caf8b.
上级 134638a3
......@@ -1563,9 +1563,10 @@ if ($artifact)
}
elsif($^O eq 'darwin')
{
$embedDirArchDestination = "$embedDirRoot/osx";
$distDirArchBin = "$distdir/bin-osx";
$versionsOutputFile = "$buildsroot/versions-osx.txt";
# Note these tmp directories will get merged into a single 'osx' directory later by a parent script
$embedDirArchDestination = "$embedDirRoot/osx-tmp-$monoHostArch";
$distDirArchBin = "$distdir/bin-osx-tmp-$monoHostArch";
$versionsOutputFile = $arch32 ? "$buildsroot/versions-osx32.txt" : "$buildsroot/versions-osx64.txt";
}
else
{
......
......@@ -51,6 +51,11 @@ GetOptions(
'buildusandboo=i'=>\$buildUsAndBoo,
);
my $monoArch32Target = "i386";
print(">>> Building $monoArch32Target\n");
system("perl", "$buildscriptsdir/build.pl", "--arch32=1", "--clean=1", "--classlibtests=0", @passAlongArgs) eq 0 or die ("failing building $monoArch32Target");
if ($artifactsCommon)
{
push @passAlongArgs, "--artifactscommon=1";
......@@ -70,7 +75,91 @@ if ($artifact)
# Merge stuff in the embedruntimes directory
my $embedDirRoot = "$buildsroot/embedruntimes";
my $embedDirDestination = "$embedDirRoot/osx";
my $embedDirSource32 = "$embedDirRoot/osx-tmp-$monoArch32Target";
my $embedDirSource64 = "$embedDirRoot/osx-tmp-x86_64";
system("mkdir -p $embedDirDestination");
if (!(-d $embedDirSource32))
{
die("Expected source directory not found : $embedDirSource32\n");
}
if (!(-d $embedDirSource64))
{
die("Expected source directory not found : $embedDirSource64\n");
}
# Create universal binaries
for my $file ('libmonobdwgc-2.0.dylib','libmonosgen-2.0.dylib','libMonoPosixHelper.dylib')
{
print(">>> lipo $embedDirSource32/$file $embedDirSource64/$file -create -output $embedDirDestination/$file\n\n");
system ('lipo', "$embedDirSource32/$file", "$embedDirSource64/$file", '-create', '-output', "$embedDirDestination/$file");
}
if (not $buildMachine)
{
print(">>> Doing non-build machine stuff...\n");
for my $file ('libmonobdwgc-2.0.dylib','libmonosgen-2.0.dylib','libMonoPosixHelper.dylib')
{
print(">>> Removing $embedDirDestination/$file.dSYM\n");
rmtree ("$embedDirDestination/$file.dSYM");
print(">>> 'dsymutil $embedDirDestination/$file\n");
system ('dsymutil', "$embedDirDestination/$file") eq 0 or warn ("Failed creating $embedDirDestination/$file.dSYM");
}
print(">>> Done with non-build machine stuff\n");
}
# Merge stuff in the monodistribution directory
my $distDirRoot = "$buildsroot/monodistribution";
my $distDirDestinationBin = "$buildsroot/monodistribution/bin";
my $distDirDestinationLib = "$buildsroot/monodistribution/lib";
my $distDirSourceBin32 = "$distDirRoot/bin-osx-tmp-$monoArch32Target";
my $distDirSourceBin64 = "$distDirRoot/bin-osx-tmp-x86_64";
# Should always exist because build_all would have put stuff in it, but in some situations
# depending on the options it may not. So create it if it does not exist
if (!(-d $distDirDestinationBin))
{
system("mkdir -p $distDirDestinationBin");
}
if (!(-d $distDirDestinationLib))
{
system("mkdir -p $distDirDestinationLib");
}
if (!(-d $distDirSourceBin32))
{
die("Expected source directory not found : $distDirSourceBin32\n");
}
if (!(-d $distDirSourceBin64))
{
die("Expected source directory not found : $distDirSourceBin64\n");
}
for my $file ('mono','pedump')
{
print(">>> lipo $distDirSourceBin32/$file $distDirSourceBin64/$file -create -output $distDirDestinationBin/$file\n\n");
system ('lipo', "$distDirSourceBin32/$file", "$distDirSourceBin64/$file", '-create', '-output', "$distDirDestinationBin/$file");
}
#Create universal binaries for stuff is in the embed dir but will end up in the dist dir
for my $file ('libMonoPosixHelper.dylib')
{
print(">>> lipo $embedDirSource32/$file $embedDirSource64/$file -create -output $distDirDestinationLib/$file\n\n");
system ('lipo', "$embedDirSource32/$file", "$embedDirSource64/$file", '-create', '-output', "$distDirDestinationLib/$file");
}
if ($buildMachine)
{
print(">>> Clean up temporary arch specific build directories\n");
rmtree("$distDirSourceBin32");
rmtree("$distDirSourceBin64");
rmtree("$embedDirSource32");
rmtree("$embedDirSource64");
}
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册