From: Marius Gavrilescu Date: Mon, 26 May 2014 18:40:53 +0000 (+0300) Subject: Add formats GCCGO, GOLANG, HASKELL X-Git-Tag: 5999.000_004~2 X-Git-Url: http://git.ieval.ro/?a=commitdiff_plain;h=5a4392d52560b78196572d6680cb76dadc6e2782;p=gruntmaster-daemon.git Add formats GCCGO, GOLANG, HASKELL --- diff --git a/gruntmaster-compile b/gruntmaster-compile index 4e60096..5228bdd 100755 --- a/gruntmaster-compile +++ b/gruntmaster-compile @@ -21,6 +21,9 @@ if ($ret) { exec 'gmcs', '-d:ONLINE_JUDGE', $name when 'MONO'; exec 'javac', $name when 'JAVA'; exec 'fpc', qw/-dONLINE_JUDGE -O2/, $name when 'PASCAL'; + exec 'go', qw/build -compiler gc/, $name when 'GOLANG'; + exec 'go', qw/build -compiler gccgo/, $name, when 'GCCGO'; + exec 'ghc', qw/-DONLINE_JUDGE -Wall -O2 -o/, $basename, $name when 'HASKELL'; copy $name, $basename when ['PERL', 'PYTHON'] } } diff --git a/lib/Gruntmaster/Daemon.pm b/lib/Gruntmaster/Daemon.pm index b7b6e06..1c8cece 100644 --- a/lib/Gruntmaster/Daemon.pm +++ b/lib/Gruntmaster/Daemon.pm @@ -23,6 +23,9 @@ use constant PAGE_SIZE => 10; use constant FORMAT_EXTENSION => { C => 'c', CPP => 'cpp', + GCCGO => 'go', + GOLANG => 'go', + HASKELL => 'hs', MONO => 'cs', JAVA => 'java', PASCAL => 'pas', diff --git a/lib/Gruntmaster/Daemon/Format.pm b/lib/Gruntmaster/Daemon/Format.pm index dc75fa1..2bfbc1a 100644 --- a/lib/Gruntmaster/Daemon/Format.pm +++ b/lib/Gruntmaster/Daemon/Format.pm @@ -24,7 +24,7 @@ sub command_and_args{ my ($format, $basename) = @_; given($format) { - "./$basename" when [qw/C CPP PASCAL/]; + "./$basename" when [qw/C CPP GCCGO GOLANG HASKELL PASCAL/]; "./$basename.exe" when 'MONO'; java => $basename when 'JAVA'; perl => $basename when 'PERL';