From cc70746e8efa6cadb23cbfcb11ddb51574c512a9 Mon Sep 17 00:00:00 2001 From: Keith Packard Date: Fri, 5 Oct 2018 21:40:13 -0700 Subject: [PATCH] doc: Use RELEASE_DATE to set PDF timestamps using faketime This ensures that the generated PDF files do not depend on the time of the build and only on the date of the release. Signed-off-by: Keith Packard --- configure.ac | 1 + doc/{Makefile => Makefile.am} | 9 +++++---- 2 files changed, 6 insertions(+), 4 deletions(-) rename doc/{Makefile => Makefile.am} (94%) diff --git a/configure.ac b/configure.ac index 9ad581c9..a14762b0 100644 --- a/configure.ac +++ b/configure.ac @@ -519,6 +519,7 @@ AC_OUTPUT([ Makefile src/Makedefs src/chaoskey-v1.0/org.altusmetrum.ChaosKey.metainfo.xml +doc/Makefile altoslib/Makefile altoslib/AltosVersion.java icon/Makefile diff --git a/doc/Makefile b/doc/Makefile.am similarity index 94% rename from doc/Makefile rename to doc/Makefile.am index 5e175cbe..0139d313 100644 --- a/doc/Makefile +++ b/doc/Makefile.am @@ -2,6 +2,8 @@ # http://docbook.sourceforge.net/release/xsl/current/README # +FAKETIME=$(RELEASE_DATE) 00:00:00 + RELNOTES_INC=\ release-notes-1.8.7.inc \ release-notes-1.8.6.inc \ @@ -245,7 +247,7 @@ PUBLISH_DOC=$(PUBLISH_HTML) $(HTML_REVHISTORY) $(PDF) $(IMAGES) $(STYLESHEET) DOC=$(HTML) $(HTML_REVHISTORY) $(PDF) $(IMAGES) $(STYLESHEET) -.SUFFIXES: .tmpl .xsl .inc .txt .raw .pdf .html +SUFFIXES = .tmpl .xsl .inc .txt .raw .pdf .html .txt.raw: sed -e 's/^[ ]*//' -e 's/^\\//' $*.txt > $@ @@ -254,12 +256,11 @@ DOC=$(HTML) $(HTML_REVHISTORY) $(PDF) $(IMAGES) $(STYLESHEET) sed -e 's/^[ ]*//' -e 's/^\\//' $*.inc > $@ .raw.html: - a2x --verbose -a docinfo -f pdf --xsltproc-opts "--stringparam toc.section.depth 2" --xsl-file $(FOP_STYLE) --fop --fop-opts="-c $(FOP_XCONF)" $*.raw - a2x --verbose -a docinfo -f xhtml --xsltproc-opts "--stringparam toc.section.depth 2" --xsl-file $(HTML_STYLE) --stylesheet=$(STYLESHEET) $*.raw + a2x -a docinfo -f xhtml --xsltproc-opts "--stringparam toc.section.depth 2" --xsl-file $(HTML_STYLE) --stylesheet=$(STYLESHEET) $*.raw case $* in release-notes*) ./fix-html $*.html ;; esac .html.pdf: - @echo $@ + TZ=UTC faketime -f '$(FAKETIME) i0' a2x -a docinfo -f pdf --xsltproc-opts "--stringparam toc.section.depth 2" --xsl-file $(FOP_STYLE) --fop --fop-opts="-c $(FOP_XCONF)" $*.raw .tmpl.xsl: xsltproc --output $@ /usr/share/xml/docbook/stylesheet/docbook-xsl/template/titlepage.xsl $*.tmpl -- 2.30.2