![](https://secure.gravatar.com/avatar/49e63acb01f2ca80efce7eed08310ce8.jpg?s=120&d=mm&r=g)
� wrote:
Hi,
we (i.e. a couple of Debian developers, taking up old ideas of each individual and the tests in http://tug.org/svn/texlive/trunk/Master/support/tests/) are trying to implement some automated testing of pdf and dvi creation by pdftex. Possible applications are regression tests for the binary, for distributions (changed font setup etc.), or for package authors ("does the new version still cooperate with hyperref?").
For this, it would be great if it were possible to create identical pdf files in subsequent runs of pdfTeX. With
\pdfinfo{/CreationDate (1980-09-09)} \year=1980 \month=9 \day=9 \time=10 \pdfcompresslevel0
I get pdf files that can be compared, but only after some grepping:
egrep -a -v '/BaseFont|/FontName|/UniqueID|/ID|/CreationDate' $< > $@
With dvipdfmx (and perhaps with newer pdfTeX versions than the one in teTeX) /CMap or something like this needs to be excluded, too.
Is it possible to achieve identical pdf files directly, by adding the proper commands, or would it be possible to add this feature?
i think that the changes are nil - pdf itself is moving which may demand additional of different resources being added - the pdftex stream depends on for instance cm directives and font references and there has been changes in this area over time (improvements like collapsing, removing redundant code) - macro packages may change their implementations of annotations, color, graphics and such, which results in different object ordering, numbering and content - macro packages may add/support new features which in turn may result in differences between pdf files; - macro packages may improve/change/patch special things (hz metrics and such) - font resources may change (metrics are normally stable, but the rest may change) the best you can do is not to look at the pdf file, but to parse the log for errors, like overfull boxes which can be signals of old/new code doing weird things, missing fonts, map files, encodings and characters. Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------