From: Michal Sojka Date: Tue, 12 Nov 2013 23:40:08 +0000 (+0100) Subject: Allow including an arbitrary file from tests in the documentation X-Git-Url: https://rtime.felk.cvut.cz/gitweb/omk.git/commitdiff_plain/a98841a6cd741ea4a906aae32e812cd7fcf1d22c?ds=sidebyside Allow including an arbitrary file from tests in the documentation --- diff --git a/doc/Makefile b/doc/Makefile index c249be4..6e6a5b3 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -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 diff --git a/doc/omk-manual.texinfo b/doc/omk-manual.texinfo index 1668043..475e2da 100644 --- a/doc/omk-manual.texinfo +++ b/doc/omk-manual.texinfo @@ -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: