From: Marius Gavrilescu Date: Wed, 11 Feb 2015 13:24:44 +0000 (+0200) Subject: Add -lm to C and CPP compilation commands X-Git-Tag: 5999.000_005~36 X-Git-Url: http://git.ieval.ro/?a=commitdiff_plain;h=5b0c03b69d4a9087ec07a92d8273b240407ff663;p=gruntmaster-daemon.git Add -lm to C and CPP compilation commands --- diff --git a/gruntmaster-compile b/gruntmaster-compile index be900b9..5af89b9 100755 --- a/gruntmaster-compile +++ b/gruntmaster-compile @@ -9,8 +9,8 @@ my ($format, $name) = @ARGV; my $basename = fileparse $name, qr/\..*/; given ($format){ - exec 'gcc', qw/-DONLINE_JUDGE -std=gnu11 -Wall -Wextra -O2 -o/, $basename, $name when 'C'; - exec 'g++', qw/-DONLINE_JUDGE -std=gnu++11 -Wall -Wextra -O2 -o/, $basename, $name when 'CPP'; + exec 'gcc', qw/-DONLINE_JUDGE -std=gnu11 -Wall -Wextra -lm -O2 -o/, $basename, $name when 'C'; + exec 'g++', qw/-DONLINE_JUDGE -std=gnu++11 -Wall -Wextra -lm -O2 -o/, $basename, $name when 'CPP'; when ('MONO') { system 'gmcs', '-d:ONLINE_JUDGE', $name and die "gmcs failed: errno=$! return=$?"; rename "$basename.exe", $basename;