3
0
Fork 0

fix docs on non-linux machines

This closes #27

[skip ci]
This commit is contained in:
Steffen Jaeckel 2021-02-04 19:09:20 +01:00
parent 55863ae1d9
commit 6a41cc4e2d
1 changed files with 5 additions and 3 deletions

View File

@ -9,16 +9,18 @@ silent=@
silent_stdout= > /dev/null
endif
all: tfm.pdf
docdvi: tfm.tex
cp tfm.tex tfm.bak
touch --reference=tfm.tex tfm.bak
touch -r 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 -r tfm.bak tfm.tex
touch tfm.ind
latex tfm $(silent_stdout)
latex tfm $(silent_stdout)
@ -31,4 +33,4 @@ tfm.pdf: docdvi
sed -b -i 's,^/ID \[.*\]$$,/ID [<0> <0>],g' tfm.pdf
mv tfm.bak tfm.tex
docs: tfm.pdf
docs: tfm.pdf