From: Martin Ågren Date: Tue, 01 Dec 2020 19:18:45 GMT Subject: Re: [PATCH] doc: make HTML manual reproducible Message-ID: In-Reply-To: <20201201154115.GP748@pobox.com> On Tue, 1 Dec 2020 at 16:41, Todd Zullinger wrote: > Arnout Engelen wrote: > > This makes sure the generated id's inside the html version of the > > documentation use the same id's when the same version of the > > manual is generated twice. Thanks for this. Your mail still hasn't reached me through the list, so I'm replying to Todd's reply here. Looking through the word-diff of the resulting user-manual.html, I see basically three changes. I've applied some light copy-editing to try to make them more readable (the lack of spaces means the notion of "word" diff is a bit off). Do you also have these three changes? 1. Git User Manual 2. 3. These names and links don't strike me as particularly useful. But even so, reproducibility makes sense. I guess you're not really after linking to these, but want to have binary-identical user-manual.html when building from the same commit? > > @@ -380,7 +380,7 @@ SubmittingPatches.txt: SubmittingPatches > > $(QUIET_GEN) cp $< $@ > > > > XSLT = docbook.xsl > > -XSLTOPTS = --xinclude --stringparam html.stylesheet docbook-xsl.css > > +XSLTOPTS = --xinclude --stringparam html.stylesheet docbook-xsl.css --stringparam generate.consistent.ids 1 Nit: Maybe add a new line XSLTOPTS += --stringparam generate.consistent.ids 1 instead to keep within 80 characters. > I think this would raise the minimum supported version of > docbook-xsl to 1.77.1. That might be fine, but we'd > probably want to make sure it doesn't negatively impact > OS/distributions which build the docs as a likely group who > care about reproducible builds. And we'd want to update the > requirement in INSTALL, of course. Thanks for digging out the version number. Agreed that this change should be reflected in INSTALL. > The minimum docbook-xsl version was raised from 1.73 to > 1.74, in 5a80d85bbe (INSTALL: drop support for docbook-xsl > before 1.74, 2020-03-29). That change was discussed in > ¹. As mentioned there, it's not like I went out and tested with 1.74. So whether we *actually* support 1.74 right now is anyone's guess. > AFAICT, the generate.consistent.ids param was added in > docbook-xsl-1.77.1 which was released in June 2012. The > commit which added it is 74735098e (New param to support > replacing generate-id() with xsl:number for more consistent > id values., 2011-10-24). > > In any case, a minimum of 1.77.1 is present in the supported > releases of CentOS/RHEL and Debian/Ubuntu, at least (most > have 1.79.x). Those are certainly not the only systems Git > cares about; they're simply the systems with which I am at > least mildly familiar. Seems to me like we can go with a change like this. If you're on a pre-1.77.1 system and want user-manual.html, but don't want to update your tool chain, you should still be able to clone the "htmldocs" repo. I'm not sure exactly where the cut-off point is, but I think moving up to mid-2012 should be ok. Martin