]> ruderich.org/simon Gitweb - blhc/blhc.git/commitdiff
Handle false positive from make.
authorSimon Ruderich <simon@ruderich.org>
Sat, 24 Mar 2012 14:19:22 +0000 (15:19 +0100)
committerSimon Ruderich <simon@ruderich.org>
Sat, 24 Mar 2012 14:19:49 +0000 (15:19 +0100)
MANIFEST
bin/blhc
t/logs/make [new file with mode: 0644]
t/tests.t

index c5b34a56e15553fa06f9b1af3c6df9ccb28cacc9..2932b8ac30a680865d1285e7e2dc419b17401789 100644 (file)
--- a/MANIFEST
+++ b/MANIFEST
@@ -32,5 +32,6 @@ t/logs/good-library
 t/logs/good-multiline
 t/logs/good-pie
 t/logs/libtool
+t/logs/make
 t/logs/verbose-build
 t/tests.t
index 5c01ada03ff269953838fef909e31f7b7cbffd96..6c3853a7975c7c296afd6cf43845747f2a5f544e 100755 (executable)
--- a/bin/blhc
+++ b/bin/blhc
@@ -466,6 +466,8 @@ while (my $line = <>) {
                     or $line =~ /^\s*(?:- )?(?:HOST_)?(?:CC|CXX)\s*=\s*$cc_regex\s*$/
                     or $line =~ /^\s*-- Check for working (?:C|CXX) compiler: /
                     or $line =~ /^\s*(?:echo )?Using [A-Z_]+\s*=\s*/;
+            # `make` output.
+            next if $line =~ /^Making [a-z]+ in \S+/; # e.g. "[...] in c++"
 
             # Check if additional hardening options were used. Used to ensure
             # they are used for the complete build.
diff --git a/t/logs/make b/t/logs/make
new file mode 100644 (file)
index 0000000..1b5b31e
--- /dev/null
@@ -0,0 +1,6 @@
+dpkg-buildpackage: source package test
+
+# Output by make which should be ignored.
+
+Making all in c++
+Making install in c++
index 46a789cbeae05714bbbe62d156394cad135f709e..3b9c332292db849b0a7b9e88b0e7cd2e2305b22b 100644 (file)
--- a/t/tests.t
+++ b/t/tests.t
@@ -19,7 +19,7 @@
 use strict;
 use warnings;
 
-use Test::More tests => 88;
+use Test::More tests => 90;
 
 
 sub is_blhc {
@@ -396,12 +396,17 @@ CFLAGS missing (-Werror=format-security): cd /tmp/test/src && /usr/bin/gcc -g -O
 ';
 
 
-# configure
+# configure/make
 
 is_blhc 'configure', '', 1,
         'No compiler commands!
 ';
 
+is_blhc 'make', '', 1,
+        'No compiler commands!
+';
+
+
 
 # cc