X-Git-Url: https://ruderich.org/simon/gitweb/?p=blhc%2Fblhc.git;a=blobdiff_plain;f=bin%2Fblhc;h=bfa954b50f2b8974ee1dbd06e855f5ee8ef668ee;hp=7b196a0ccf93a6d6ea521e5f7650847021852c00;hb=36c9f05a7471f321df247f0237ac8efa81d69207;hpb=5ba101e4f167d461647d9481f83528d5151bafac diff --git a/bin/blhc b/bin/blhc index 7b196a0..bfa954b 100755 --- a/bin/blhc +++ b/bin/blhc @@ -317,7 +317,7 @@ sub is_non_verbose_build { if (defined $file) { # Get filename, we can't use the complete path as only parts of it are # used in the real compiler command. - $file =~ m{/([a-zA-Z0-9._-]+)$}; + $file =~ m{/([^/\s]+)$}; $file = $1; if ($next_line =~ /\Q$file\E/ and $next_line =~ /$cc_regex/o) { @@ -655,6 +655,9 @@ FILE: foreach my $file (@ARGV) { # Remove everything until and including the compiler command. Makes # checks easier and faster. $line =~ s/^.*?$cc_regex//o; + # "([...] test.c)" is not detected as 'test.c' - fix this by removing + # the brace and similar characters. + $line =~ s/['")]+$//; # Skip unnecessary tests when only preprocessing. my $flag_preprocess = 0;