+
+.PHONY: ps_$1
+ifeq "$$(BUILD_DOCBOOK_PS)" "YES"
+$(call all-target,$1,ps_$1)
+INSTALL_DOCS += $1/$2.ps
+endif
+
+ps_$1 : $1/$2.ps
+
+ifneq "$$(BINDIST)" "YES"
+$1/$2.ps: $$($1_DOCBOOK_SOURCES)
+ "$$(DBLATEX)" $$(DBLATEX_OPTS) $1/$2.xml --ps -o $$@
+ [ -f $$@ ]
+endif
+
+ifeq "$$(BUILD_DOCBOOK_PDF)" "YES"
+$(call all-target,$1,pdf_$1)
+INSTALL_DOCS += $1/$2.pdf
+endif
+
+.PHONY: pdf_$1
+pdf_$1 : $1/$2.pdf
+
+ifneq "$$(BINDIST)" "YES"
+$1/$2.pdf: $$($1_DOCBOOK_SOURCES)
+ "$$(DBLATEX)" $$(DBLATEX_OPTS) $1/$2.xml --pdf -o $$@
+ [ -f $$@ ]
+endif
+