diff --git a/makefile b/makefile index 4eea681..60b10fb 100644 --- a/makefile +++ b/makefile @@ -125,6 +125,15 @@ rsatest: $(LIBNAME) demo/rsa.o $(CC) $(CFLAGS) demo/rsa.o $(LIBNAME) -o rsatest docdvi: tfm.tex + cp tfm.tex tfm.bak + touch --reference=tfm.tex tfm.bak + (printf "%s" "\def\fixedpdfdate{"; date +'D:%Y%m%d%H%M%S%:z' -d @$$(stat --format=%Y tfm.tex) | sed "s/:\([0-9][0-9]\)$$/'\1'}/g") > tfm-deterministic.tex + printf "%s\n" "\pdfinfo{" >> tfm-deterministic.tex + printf "%s\n" " /CreationDate (\fixedpdfdate)" >> tfm-deterministic.tex + printf "%s\n}\n" " /ModDate (\fixedpdfdate)" >> tfm-deterministic.tex + cat tfm.tex >> tfm-deterministic.tex + mv tfm-deterministic.tex tfm.tex + touch --reference=tfm.bak tfm.tex touch tfm.ind latex tfm >/dev/null latex tfm >/dev/null @@ -133,7 +142,9 @@ docdvi: tfm.tex docs: docdvi latex tfm >/dev/null - dvipdf tfm + pdflatex tfm >/dev/null + sed -b -i 's,^/ID \[.*\]$$,/ID [<0> <0>],g' tfm.pdf + mv tfm.bak tfm.tex mv -f tfm.pdf doc #This rule cleans the source tree of all compiled code, not including the pdf