move the creation of the manpage-style.xsl file to the rest of the
authorDavid Kalnischkies <kalnischkies@gmail.com>
Sun, 20 May 2012 16:37:14 +0000 (18:37 +0200)
committerDavid Kalnischkies <kalnischkies@gmail.com>
Sun, 20 May 2012 16:37:14 +0000 (18:37 +0200)
manpage building instead of doing it at setup time, so we can properly
depend on it

buildlib/po4a_manpage.mak
doc/makefile

index 5814180..1dedd0d 100644 (file)
@@ -28,7 +28,11 @@ veryclean: veryclean/$(LOCAL)
 apt-verbatim.ent: ../apt-verbatim.ent
        cp ../apt-verbatim.ent .
 
-$($(LOCAL)-LIST) :: % : %.xml $(INCLUDES)
+manpage-style.xsl: ../manpage-style.xsl
+       sed "/<!-- LANGUAGE -->/ i\
+<xsl:param name=\"l10n.gentext.default.language\" select=\"'$(LC)'\" />" ../manpage-style.xsl > manpage-style.xsl
+
+$($(LOCAL)-LIST) :: % : %.xml $(STYLESHEET) $(INCLUDES)
        echo Creating man page $@
        $(XSLTPROC) -o $@ $(STYLESHEET) $< || exit 200 # why xsltproc doesn't respect the -o flag here???
        test -f $(subst .$(LC),,$@) || echo FIXME: xsltproc respect the -o flag now, workaround can be removed
index 76e29e2..4c0a431 100644 (file)
@@ -29,7 +29,7 @@ $(LOCAL)-LIST := $(SOURCE)
 # Install generation hooks
 manpages: $(MANPAGEPOLIST) $($(LOCAL)-LIST)
 
-$($(LOCAL)-LIST) :: % : %.xml $(INCLUDES)
+$($(LOCAL)-LIST) :: % : %.xml $(STYLESHEET) $(INCLUDES)
        echo Creating man page $@
        $(XSLTPROC) -o $@ $(STYLESHEET) $<
 
@@ -42,8 +42,6 @@ dirs-manpage-subdirs:
        for i in $(MANPAGEPO); do \
                test -d $$i || mkdir $$i; \
                test -f $$i/makefile || sed "s#@@LANG@@#$$i#" lang.makefile > $$i/makefile; \
-               test -f $$i/manpage-style.xsl || sed "/<!-- LANGUAGE -->/ i\
-<xsl:param name=\"l10n.gentext.default.language\" select=\"'$$i'\" />" manpage-style.xsl > $$i/manpage-style.xsl; \
        done
 
 # Clean rule