]> rtime.felk.cvut.cz Git - omk.git/commitdiff
Added test for command line specified CFLAGS.
authorMichal Sojka <sojkam1@fel.cvut.cz>
Tue, 23 Oct 2007 09:51:00 +0000 (09:51 +0000)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Tue, 23 Oct 2007 09:51:00 +0000 (09:51 +0000)
darcs-hash:20071023095108-f2ef6-6f01db841913b1538ce1887f9dbe92b4ffaf6e1b.gz

tests/libraries/Makefile.omk
tests/programs/runtest-cflags-cmdline [new file with mode: 0755]

index 5d8befd0f8287d97236b8cb6990dfbcd64b6c21d..3e76540c537980d650bb10df613b6d72a1838414 100644 (file)
@@ -1,3 +1,3 @@
 lib_LIBRARIES = mylib
 mylib_SOURCES = funca.c funcb.c
-include_HEADERS mylib.h
+include_HEADERS mylib.h
diff --git a/tests/programs/runtest-cflags-cmdline b/tests/programs/runtest-cflags-cmdline
new file mode 100755 (executable)
index 0000000..a4eb15c
--- /dev/null
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+source ../functions.sh
+
+touch config.omk-default
+make CFLAGS="-DNONSENSE=abc -DNUMBER=123"||canttest "Can't compile"
+[ $OMK_RULES != linux ] && canttest "Should work only with Linux rules"
+_compiled/bin/test|grep 123 || error "Custom CFLAGS didn't influence the output"