# Ignore false positives.
#
# ./configure summary.
- next if $line =~ /^Compiler:\s+(cc|gcc|g\+\+|c\+\+)$/;
+ my $cc_regex = qr/(cc|(x86_64-linux-gnu-)?gcc|g\+\+|c\+\+)/;
+ next if $line =~ /^\s*(C|c)ompiler[\s.]*:\s+$cc_regex(\s-std=[a-z0-9:+]+)?\s*$/
+ or $line =~ /^\s*- (CC|CXX)\s*=\s*$cc_regex\s*$/
+ or $line =~ /^\s*-- Check for working (C|CXX) compiler: /;
# Is this a compiler or linker command?
my $compiler = 1;