my $option_version = 0;
my $option_pie = 0;
my $option_bindnow = 0;
+my @option_ignore_arch = ();
my @option_ignore_flag = ();
my @option_ignore_line = ();
my $option_all = 0;
'bindnow' => \$option_bindnow,
'all' => \$option_all,
# Ignore.
+ 'ignore-arch=s' => \@option_ignore_arch,
'ignore-flag=s' => \@option_ignore_flag,
'ignore-line=s' => \@option_ignore_line,
# Misc.
close $fh;
+ # Ignore arch if requested.
+ if (scalar @option_ignore_arch > 0 and $arch) {
+ foreach my $ignore (@option_ignore_arch) {
+ if ($arch eq $ignore) {
+ print "ignoring architecture '$arch'\n";
+ next FILE;
+ }
+ }
+ }
+
if (scalar @input == 0) {
if (not $option_buildd) {
print "No compiler commands!\n";
Use colored (ANSI) output for warning messages.
+=item B<--ignore-arch> I<arch>
+
+Ignore build logs from architectures matching I<arch>. I<arch> is a string.
+
+Used to prevent false positives. This option can be specified multiple times.
+
=item B<--ignore-flag> I<flag>
Don't print an error when the specific flag is missing in a compiler line.
use strict;
use warnings;
-use Test::More tests => 132;
+use Test::More tests => 134;
sub is_blhc {
';
+# ignore architecture
+
+is_blhc ['arch-avr32', 'arch-i386', 'empty', 'arch-mipsel'],
+ '--ignore-arch avr32 --ignore-arch mipsel',
+ 9,
+ "checking './t/logs/arch-avr32'...\n"
+ . "ignoring architecture 'avr32'\n"
+ . "checking './t/logs/arch-i386'...\n"
+ . $arch_i386
+ . "checking './t/logs/empty'...\n"
+ . $empty
+ . "checking './t/logs/arch-mipsel'...\n"
+ . "ignoring architecture 'mipsel'\n"
+ ;
+
+
# debian
is_blhc 'debian', '', 8,