]> ruderich.org/simon Gitweb - blhc/blhc.git/blobdiff - t/tests.t
First work on --buildd.
[blhc/blhc.git] / t / tests.t
index 6ec7c6938928aa1f6f538a84f85c9ef6e556e9f6..3c7e5b8af91a09851b5bc19f818a56ff5fcba4b9 100644 (file)
--- a/t/tests.t
+++ b/t/tests.t
@@ -19,7 +19,7 @@
 use strict;
 use warnings;
 
-use Test::More tests => 80;
+use Test::More tests => 84;
 
 
 sub is_blhc {
@@ -50,6 +50,7 @@ Usage:
         --bindnow               force +bindbow check
         --all                   force +all (+pie, +bindnow) check
         --arch                  set architecture (autodetected)
+        --buildd                parser mode for buildds
 
 ';
 
@@ -309,6 +310,16 @@ NONVERBOSE BUILD:   CC     libtest-b.lo
 NONVERBOSE BUILD:   CC     libtest_c.lo
 NONVERBOSE BUILD:   CC     libtest-d.lo
 NONVERBOSE BUILD:   CCLD   libtest.la
+NONVERBOSE BUILD:   CXX    libtest-a.lo
+NONVERBOSE BUILD:   CXX    libtest-b.lo
+NONVERBOSE BUILD:   CXX    libtest_c.lo
+NONVERBOSE BUILD:   CXX    libtest-d.lo
+NONVERBOSE BUILD:   CXXLD  libtest.la
+NONVERBOSE BUILD:       [CC]   src/test-a.o
+NONVERBOSE BUILD:       [CC]   src/test-b.o
+NONVERBOSE BUILD:       [CC]   src/test_c.o
+NONVERBOSE BUILD:       [CXX]  src/test-d.o
+NONVERBOSE BUILD:       [LD]   src/test.o
 NONVERBOSE BUILD:       [CC]   src/test-a.o
 NONVERBOSE BUILD:       [CC]   src/test-b.o
 NONVERBOSE BUILD:       [CC]   src/test_c.o
@@ -367,13 +378,6 @@ LDFLAGS missing (-fPIE -pie -Wl,-z,now): gcc-4.6 -Wl,-z,defs test-a.o test-b.o t
 ';
 
 
-# debian
-
-is_blhc 'debian', '', 8,
-        'CPPFLAGS missing (-D_FORTIFY_SOURCE=2): gcc -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security -Wall -c test.c
-';
-
-
 # c++
 
 is_blhc 'c++', '--pie --bindnow', 8,
@@ -463,3 +467,36 @@ is_blhc 'arch-mipsel', '', 8,
         'CFLAGS missing (-Werror=format-security): gcc -D_FORTIFY_SOURCE=2 -g -O2 -Wformat -Wformat-security -Wall -c test.c
 LDFLAGS missing (-Wl,-z,relro): gcc -Wl,-z,now -o test test.o
 ';
+
+
+# debian
+
+is_blhc 'debian', '', 8,
+        'CPPFLAGS missing (-D_FORTIFY_SOURCE=2): gcc -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security -Wall -c test.c
+';
+
+
+# buildd support
+
+is_blhc 'buildd-dpkg-dev', '--buildd', 8,
+        'CFLAGS missing (-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security): gcc -g -O2 -c test-a.c
+CPPFLAGS missing (-D_FORTIFY_SOURCE=2): gcc -g -O2 -c test-a.c
+CFLAGS missing (-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security): gcc -g -O2 -c test-b.c
+CPPFLAGS missing (-D_FORTIFY_SOURCE=2): gcc -g -O2 -c test-b.c
+CFLAGS missing (-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security): gcc -g -O2 -c test-c.c
+CPPFLAGS missing (-D_FORTIFY_SOURCE=2): gcc -g -O2 -c test-c.c
+LDFLAGS missing (-Wl,-z,relro): gcc -o test test-a.o test-b.o test-c.o -ltest
+CFLAGS missing (-O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security): gcc -g -c test-a.c
+CPPFLAGS missing (-D_FORTIFY_SOURCE=2): gcc -g -c test-a.c
+CFLAGS missing (-O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security): gcc -g -c test-b.c
+CPPFLAGS missing (-D_FORTIFY_SOURCE=2): gcc -g -c test-b.c
+CFLAGS missing (-O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security): gcc -g -c test-c.c
+CPPFLAGS missing (-D_FORTIFY_SOURCE=2): gcc -g -c test-c.c
+LDFLAGS missing (-Wl,-z,relro): gcc -o test test-a.o test-b.o test-c.o -ltest
+';
+
+is_blhc 'buildd-dpkg-dev-old', '--buildd', 8,
+        'CFLAGS missing (-O2): gcc -g -c test-a.c
+CFLAGS missing (-O2): gcc -g -c test-b.c
+CFLAGS missing (-O2): gcc -g -c test-c.c
+';