X-Git-Url: https://ruderich.org/simon/gitweb/?a=blobdiff_plain;f=bin%2Fblhc;h=fa2c507fff10c679a94d277b3b95571bf7cebe31;hb=0261fdd4ff435c302e6e85bfb1954940e004c26b;hp=704d323694031709909d15becefea70ab006ffee;hpb=ae5da64f4f6f53ca3eb055d2124988847b2e8d50;p=blhc%2Fblhc.git diff --git a/bin/blhc b/bin/blhc index 704d323..fa2c507 100755 --- a/bin/blhc +++ b/bin/blhc @@ -117,6 +117,7 @@ my @object = ( # Hashes for fast extensions lookup to check if a file falls in one of these # categories. my %extensions_no_preprocess = map { $_ => 1 } ( + # There's no @header_no_preprocess. @source_no_preprocess, ); my %extensions_preprocess = map { $_ => 1 } ( @@ -979,18 +980,18 @@ LINE: } if (not $flag_preprocess) { - # If there are source files then it's compiling/linking in one step - # and we must check both. We only check for source files here, because - # header files cause too many false positives. + # If there are source files then it's compiling/linking in one + # step and we must check both. We only check for source files + # here, because header files cause too many false positives. if (extension_found(\%extensions_compile_link, @extensions)) { - # Assembly files don't need CFLAGS. - if (not extension_found(\%extensions_compile, @extensions) - and extension_found(\%extensions_no_compile, @extensions)) { - $compile = 0; - # But the rest does. - } else { - $compile = 1; - } + # Assembly files don't need CFLAGS. + if (not extension_found(\%extensions_compile, @extensions) + and extension_found(\%extensions_no_compile, @extensions)) { + $compile = 0; + # But the rest does. + } else { + $compile = 1; + } # No compilable extensions found, either linking or compiling # header flags. # @@ -1184,7 +1185,8 @@ Don't require Term::ANSIColor. =item * -Return exit code 0, unless there was a error. +Return exit code 0, unless there was a error (-I, -W messages don't count as +error). =back