diff options
author | Jon TURNEY <jon.turney@dronecode.org.uk> | 2015-06-12 13:30:50 +0100 |
---|---|---|
committer | Jon TURNEY <jon.turney@dronecode.org.uk> | 2015-06-16 10:28:49 +0100 |
commit | 38529ea03a86161acef137bb74be276c5c7fcf8c (patch) | |
tree | 90008e15d2be52cf6436bcb3c12808cdb70a6d45 | |
parent | c46fe19460b7600e9404210338e8a159060129e4 (diff) | |
download | cygnal-38529ea03a86161acef137bb74be276c5c7fcf8c.tar.gz cygnal-38529ea03a86161acef137bb74be276c5c7fcf8c.tar.bz2 cygnal-38529ea03a86161acef137bb74be276c5c7fcf8c.zip |
winsup/doc: Make it easier to extend xidepend to more targets
Change xidepend to create a variable containing all the XIncluded sources, which
can be used as a dependency, rather than writing the dependency target itself.
Future work: Makefile.dep should depend on xidepend, but xidepend should not be
passed to itself.
2015-06-12 Jon Turney <jon.turney@dronecode.org.uk>
* xidepend: Write a Makefile fragment defining variables
containing all the XIncluded sources, rather than a dependency on
those sources.
* Makefile.in: Use that variable to express the dependency.
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
-rw-r--r-- | winsup/doc/ChangeLog | 7 | ||||
-rw-r--r-- | winsup/doc/Makefile.in | 15 | ||||
-rwxr-xr-x | winsup/doc/xidepend | 2 |
3 files changed, 15 insertions, 9 deletions
diff --git a/winsup/doc/ChangeLog b/winsup/doc/ChangeLog index c364b8d8c..937cb39c7 100644 --- a/winsup/doc/ChangeLog +++ b/winsup/doc/ChangeLog @@ -1,5 +1,12 @@ 2015-06-12 Jon Turney <jon.turney@dronecode.org.uk> + * xidepend: Write a Makefile fragment defining variables + containing all the XIncluded sources, rather than a dependency on + those sources. + * Makefile.in: Use that variable to express the dependency. + +2015-06-12 Jon Turney <jon.turney@dronecode.org.uk> + * Makefile.in (cygwin-ug-net/cygwin-ug-net.pdf) (cygwin-api/cygwin-api.pdf): Use fo.xsl to customized DocBook XML->PDF conversion. diff --git a/winsup/doc/Makefile.in b/winsup/doc/Makefile.in index 2d71728d5..14a8f22c7 100644 --- a/winsup/doc/Makefile.in +++ b/winsup/doc/Makefile.in @@ -28,6 +28,7 @@ CC_FOR_TARGET:=@CC@ XMLTO:=xmlto --skip-validation --with-dblatex include $(srcdir)/../Makefile.common +-include Makefile.dep FAQ_SOURCES:= $(wildcard $(srcdir)/faq*.xml) @@ -61,7 +62,7 @@ install-all: install-pdf install-html install-pdf: cygwin-ug-net/cygwin-ug-net.pdf cygwin-api/cygwin-api.pdf @$(MKDIRP) $(DESTDIR)$(docdir) $(INSTALL_DATA) $^ $(DESTDIR)$(docdir) - + install-html: cygwin-ug-net/cygwin-ug-net.html cygwin-api/cygwin-api.html @$(MKDIRP) $(DESTDIR)$(htmldir)/cygwin-ug-net $(INSTALL_DATA) cygwin-ug-net/*.html $(DESTDIR)$(htmldir)/cygwin-ug-net @@ -70,22 +71,22 @@ install-html: cygwin-ug-net/cygwin-ug-net.html cygwin-api/cygwin-api.html $(INSTALL_DATA) cygwin-api/*.html $(DESTDIR)$(htmldir)/cygwin-api $(INSTALL_DATA) cygwin-api/cygwin-api.html $(DESTDIR)$(htmldir)/cygwin-api/index.html -cygwin-ug-net/cygwin-ug-net-nochunks.html.gz : cygwin-ug-net.xml +cygwin-ug-net/cygwin-ug-net-nochunks.html.gz : $(cygwin-ug-net_SOURCES) cygwin.xsl -$(XMLTO) html-nochunks -m $(srcdir)/cygwin.xsl $< -cp cygwin-ug-net.html cygwin-ug-net/cygwin-ug-net-nochunks.html -rm -f cygwin-ug-net/cygwin-ug-net-nochunks.html.gz -gzip cygwin-ug-net/cygwin-ug-net-nochunks.html -cygwin-ug-net/cygwin-ug-net.html : cygwin-ug-net.xml cygwin.xsl +cygwin-ug-net/cygwin-ug-net.html : $(cygwin-ug-net_SOURCES) cygwin.xsl -$(XMLTO) html -o cygwin-ug-net/ -m $(srcdir)/cygwin.xsl $< -cygwin-ug-net/cygwin-ug-net.pdf : cygwin-ug-net.xml fo.xsl +cygwin-ug-net/cygwin-ug-net.pdf : $(cygwin-ug-net_SOURCES) fo.xsl -$(XMLTO) pdf -o cygwin-ug-net/ -m $(srcdir)/fo.xsl $< -cygwin-api/cygwin-api.html : cygwin-api.xml cygwin.xsl +cygwin-api/cygwin-api.html : $(cygwin-api_SOURCES) cygwin.xsl -$(XMLTO) html -o cygwin-api/ -m $(srcdir)/cygwin.xsl $< -cygwin-api/cygwin-api.pdf : cygwin-api.xml fo.xsl +cygwin-api/cygwin-api.pdf : $(cygwin-api_SOURCES) fo.xsl -$(XMLTO) pdf -o cygwin-api/ -m $(srcdir)/fo.xsl $< faq/faq.html : $(FAQ_SOURCES) @@ -94,5 +95,3 @@ faq/faq.html : $(FAQ_SOURCES) Makefile.dep: cygwin-ug-net.xml cygwin-api.xml cd $(srcdir) && ./xidepend $^ > "${CURDIR}/$@" - --include Makefile.dep diff --git a/winsup/doc/xidepend b/winsup/doc/xidepend index f4766209e..cc04f4a12 100755 --- a/winsup/doc/xidepend +++ b/winsup/doc/xidepend @@ -16,7 +16,7 @@ do then # This file uses XIncludes. Let's chase its deps recursively. base=`basename "$f" .xml` - if [ $subproc -eq 0 ] ; then echo -n "$base/$base.html $base/$base.pdf:" ; fi + if [ $subproc -eq 0 ] ; then echo -n "${base}_SOURCES=${f}" ; fi deps=`grep 'xi:include.*href' "$f" | cut -f2 -d\" | tr '\n' ' '` echo -n " $deps" |