X-Git-Url: https://ruderich.org/simon/gitweb/?p=blhc%2Fblhc.git;a=blobdiff_plain;f=bin%2Fblhc;h=aecc18052b83d5b06526bd492cada20739e07db6;hp=47d464c1b9b66f752bbf3e2a7ac54e75f957ff1d;hb=26504b77eea8eab454c143f50c3a4da4ba63a178;hpb=1ba912b03dd1df9a4068b567939ea2d100c56f20 diff --git a/bin/blhc b/bin/blhc index 47d464c..aecc180 100755 --- a/bin/blhc +++ b/bin/blhc @@ -44,6 +44,14 @@ sub error_flags { error_color($message, 'red'), $flags, error_color(':', 'yellow'), $line; } +sub error_nonverbose_build { + my ($line) = @_; + + printf "%s%s %s", + error_color('NONVERBOSE BUILD', 'red'), + error_color(':', 'yellow'), + $line; +} sub error_color { my ($message, $color) = @_; @@ -206,6 +214,16 @@ while (my $line = <>) { # Ignore compiler warnings for now. next if $line =~ /$warning_regex/; + # Try to detect non verbose build logs. + if ($line =~ /^checking if you want to see long compiling messages\.\.\. no/ + or $line =~ /^\s*(CC|CCLD)\s+/ + or $line =~ /^\s*(C|c)ompiling\s+/ + or $line =~ /^\s*\[[\d ]+%\] Building /) { + error_nonverbose_build($line); + $exit |= 1 << 2; + } + + # One line may contain multiple commands (";"). Treat each one as single # line. my @line = split /(? +Non verbose build. + +=item B<8> + Missing hardening flags. =back