From 2d15c81313ce7cc2c20b2f51cc225a8a8bdf8a29 Mon Sep 17 00:00:00 2001 From: Ykkrosh Date: Fri, 27 Mar 2009 01:19:55 +0000 Subject: [PATCH] # Updated autobuilder to build Atlas (and also Collada), via options in the admin UI This was SVN commit r6792. --- source/tools/autobuild2/manage.cgi | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/source/tools/autobuild2/manage.cgi b/source/tools/autobuild2/manage.cgi index 234b03cd77..f79b76aed8 100755 --- a/source/tools/autobuild2/manage.cgi +++ b/source/tools/autobuild2/manage.cgi @@ -29,6 +29,11 @@ my $ec2 = new Net::Amazon::EC2( SecretAccessKey => $config{aws_secret_access_key}, ); +my @build_options = ( + { name => 'atlas', title => 'Atlas DLL' }, + { name => 'collada', title => 'Collada DLL' }, +); + my $action = $cgi->url_param('action'); if (not defined $action or $action eq 'index') { @@ -139,7 +144,13 @@ EOF if ($got_active_instance) { print qq{\n}; } else { - print qq{
\n}; + print qq{
\n}; + print qq{
Build options\n}; + for (@build_options) { + print qq{
}; + } + print qq{\n}; + print qq{
\n}; } } @@ -291,6 +302,14 @@ sub create_user_data { for (@files) { $zip->addFile("$root/$_", "$_") or die "Failed to add $root/$_ to zip"; } + + my %options; + for (@build_options) { + $options{$_->{name}} = ($cgi->param('option_'.$_->{name}) ? 1 : 0); + } + my $options = Dumper \%options; + $zip->addString($options, 'options.pl') or die "Failed to add options.pl to zip"; + my $fh = new IO::String; if ($zip->writeToFileHandle($fh) != Archive::Zip::AZ_OK) { die "writeToFileHandle failed";