NAME = dxfngc DB_DIR = /usr/share/xml/docbook DB_SCHEMA = $(DB_DIR)/schema/xsd/5.0/docbook.xsd DB_XSL_FO = $(DB_DIR)/stylesheet/docbook-xsl-ns/fo/docbook.xsl .PHONY: all clean .SUFFIXES: .SECONDARY: all: $(NAME).pdf %.fo: %.xml xmlstarlet val --err --xsd $(DB_SCHEMA) $< xsltproc $(DB_XSL_FO) $< >$@ %.pdf: %.fo fop -fo $< -pdf $@ clean: rm -f $(NAME).fo $(NAME).pdf