From f767569767b7a1a07309b90ead34a1b88b9e0f29 Mon Sep 17 00:00:00 2001
From: Michael Smith <xmldoc@users.sourceforge.net>
Date: Fri, 1 Apr 2005 15:06:35 +0000
Subject: [PATCH] cvstools/Makefile, include instead of hard-coding application
 names; "depends.tabular" and "depends.textonly", switched to instead of
 .tabular and .textonly names, to match names in
 ../website/xsl/makefile-dep.xsl; "realclean" target added (to remove depends)

---
 website/example/Makefile | 49 ++++++++++++++++++++++++----------------
 1 file changed, 29 insertions(+), 20 deletions(-)

diff --git a/website/example/Makefile b/website/example/Makefile
index 53b3ab854..da5017aca 100644
--- a/website/example/Makefile
+++ b/website/example/Makefile
@@ -1,5 +1,5 @@
-PROC=saxon
-PROCOPT=-q
+include ../../cvstools/Makefile.incl
+XSLTOPT=-q
 TABSTYLE=../xsl/tabular.xsl
 WEBSTYLE=../xsl/website.xsl
 TABCHUNK=../xsl/chunk-tabular.xsl
@@ -11,44 +11,53 @@ USETIDY=1
 .PHONY : clean
 
 all:
-	make website
-	make TEXTONLY=1 website
+	$(MAKE) website
+	$(MAKE) TEXTONLY=1 website
 
 ifeq ($(TEXTONLY),0)
 STYLESHEET=$(TABSTYLE)
 STYLECHUNK=$(TABCHUNK)
 TEXTOPT=
-include .tabular
+include depends.tabular
 else
 STYLESHEET=$(WEBSTYLE)
 STYLECHUNK=$(WEBCHUNK)
 TEXTOPT=filename-prefix=txt
-include .textonly
+include depends.textonly
 endif
 
 autolayout.xml: layout.xml
-	xjparse $(filter-out autolayout.xml,$^)
-	$(PROC) $(PROCOPT) $< ../xsl/autolayout.xsl $@
-	make depends
+	$(XJPARSE) $(filter-out autolayout.xml,$^)
+	$(XSLT) $(XSLTOPT) $< ../xsl/autolayout.xsl $@
 
 chunk: autolayout.xml
-	$(PROC) $(PROCOPT) autolayout.xml $(STYLECHUNK) - output-root=$(DESTPATH)
+	$(XSLT) $(XSLTOPT) autolayout.xml $(STYLECHUNK) - output-root=$(DESTPATH)
 
 %.html: autolayout.xml 
-	xjparse $(filter-out autolayout.xml,$^)
-	$(PROC) $(PROCOPT) $(filter-out autolayout.xml,$^) $(STYLESHEET) $@ $(TEXTOPT) $(STYLEOPT)
+	$(XJPARSE) $(filter-out autolayout.xml,$^)
+	$(XSLT) $(XSLTOPT) $(filter-out autolayout.xml,$^) $(STYLESHEET) $@ $(TEXTOPT) $(STYLEOPT)
 ifeq ($(USETIDY),1)
-	-tidy -iq -latin1 -mn $@
+	-$(TIDY) -iq -latin1 -mn $@
 endif
 
 # RDDL gets its own rule because we never want to call tidy on it
 rddl.html: autolayout.xml
-	xjparse $(filter-out autolayout.xml,$^)
-	$(PROC) $(PROCOPT) $(filter-out autolayout.xml,$^) $(STYLESHEET) $@ $(TEXTOPT) $(STYLEOPT)
+	$(XJPARSE) $(filter-out autolayout.xml,$^)
+	$(XSLT) $(XSLTOPT) $(filter-out autolayout.xml,$^) $(STYLESHEET) $@ $(TEXTOPT) $(STYLEOPT)
 
-depends: autolayout.xml
-	xjparse $<
-	$(PROC) $(PROCOPT) $< ../xsl/makefile-dep.xsl .tabular
-	$(PROC) $(PROCOPT) $< ../xsl/makefile-dep.xsl .textonly prefix=txt
-	$(PROC) $(PROCOPT) $< ../xsl/website-targets.xsl website.database.xml
+depends.tabular: autolayout.xml
+	$(XJPARSE) $<
+	$(XSLT) $(XSLTOPT) $< ../xsl/makefile-dep.xsl $@
 
+depends.textonly: autolayout.xml
+	$(XJPARSE) $<
+	$(XSLT) $(XSLTOPT) $< ../xsl/makefile-dep.xsl $@ prefix=txt
+
+website.database.xml: autolayout.xml
+	$(XJPARSE) $<
+	$(XSLT) $(XSLTOPT) $< ../xsl/website-targets.xsl $@
+
+depends: depends.tabular depends.textonly website.database.xml
+
+realclean: clean
+	rm -f depends.tabular depends.textonly website.database.xml autolayout.xml
-- 
2.40.0