summaryrefslogtreecommitdiff
path: root/doc/Makefile
diff options
context:
space:
mode:
authorMartin Mares <mj@ucw.cz>2000-05-31 11:35:47 +0000
committerMartin Mares <mj@ucw.cz>2000-05-31 11:35:47 +0000
commit46527a939e97a8a0d6d023ad7853e5e9a2df1ea9 (patch)
tree25952d3992acd188715012deac066eb94eb61217 /doc/Makefile
parentfcb5f4a725c9edecca7d4646c633e42f66ab53b6 (diff)
Modified the Makefile to work in the source tree.
From now, you can just `make userdocs' in doc, no need to use ugly scripts. Also, `make progdocs' builds the programmer's documentation in HTML, LaTeX version to come later.
Diffstat (limited to 'doc/Makefile')
-rw-r--r--doc/Makefile26
1 files changed, 19 insertions, 7 deletions
diff --git a/doc/Makefile b/doc/Makefile
index 065323d0..9346b7d7 100644
--- a/doc/Makefile
+++ b/doc/Makefile
@@ -1,10 +1,21 @@
root-rel=../
dir-name=doc
+ifneq ($(wildcard ../Rules),)
include ../Rules
+else
+srcdir=$(shell cd $(root-rel) ; pwd)
+srcdir_abs=$(srcdir)
+endif
-progdocs:
- mkdir -p prog
+# Force rebuilds
+.PHONY: prog.sgml bird.sgml
+
+docs: progdocs userdocs
+
+progdocs: prog.html
+
+prog.sgml:
$(srcdir)/tools/progdoc $(srcdir_abs)
%.html: %.sgml
@@ -13,16 +24,17 @@ progdocs:
%.info: %.sgml
sgml2info $<
-%.txt: %.sgml
- sgml2txt $<
-
%.dvi: %.sgml
./sgml2latex $<
%.tex: %.sgml
./sgml2latex --output=tex $<
-userdocs: bird.html bird.dvi
+%.txt: %.sgml
+ ./sgml2txt $<
+
+userdocs: bird.html bird.dvi bird.txt
clean:
- rm *.html *.tex *.dvi *.log
+ rm -f *.html *.tex *.dvi *.log *.ps *.txt
+ rm -f prog.sgml