]> rtime.felk.cvut.cz Git - omk.git/commitdiff
Allow including an arbitrary file from tests in the documentation
authorMichal Sojka <sojkam1@fel.cvut.cz>
Tue, 12 Nov 2013 23:40:08 +0000 (00:40 +0100)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Tue, 12 Nov 2013 23:40:08 +0000 (00:40 +0100)
doc/Makefile
doc/omk-manual.texinfo

index c249be45fe07709070f9ddf243faf4fdb8e4d90c..6e6a5b3b488709f08e0b0f9f8f072a9d4870e3c0 100644 (file)
@@ -22,7 +22,7 @@ tests/%: DIR=$(shell echo $@|sed -e 's,\([^/]*/[^/]*\)/.*,\1,')
 tests/%:
        rm -rf $(DIR)
        mkdir -p $(DIR)
-       echo 'WVSTART() { if [ "$$WV" ]; then exit; else WV=1; fi; }; WVPASS() { :; }; needs_valid_CC() { :; }; omkize() { :; }' > $(DIR)/wvtest.sh
+       echo 'WVSTART() { local d=$(CURDIR)/$(DIR)/$$(echo $$1|tr " " -|tr A-Z a-z); mkdir -p $$d && cd $$d; }; WVPASS() { :; }; needs_valid_CC() { :; }; omkize() { :; }' > $(DIR)/wvtest.sh
        cd $(DIR) && ../../../$(DIR)
 
 %.pdf: %.png
index 16680435fbbce04628615a9b29ca2f14e474641a..475e2da7bfd89d1eba35bdd5a6cefe51313304f5 100644 (file)
@@ -325,7 +325,7 @@ In the example bellow program @command{test} will be compiled from
 source @file{test.c}.
 
 @example
-@verbatiminclude tests/programs/Makefile.omk
+@verbatiminclude tests/programs/compile-a-single-source-c-program/Makefile.omk
 @end example
 
 @noindent The variables are:
@@ -399,7 +399,7 @@ is defined in @file{myfunc.h}. Therefore, we export this header for use
 by other programs.
 
 @example
-@verbatiminclude tests/libraries/Makefile.omk
+@verbatiminclude tests/libraries/static-library/Makefile.omk
 @end example
 
 @noindent Variables for use with libraries are: