]> git.ipfire.org Git - thirdparty/dbus.git/commitdiff
docs: generate reproducible ids
authorArnout Engelen <arnout@bzzt.net>
Thu, 5 Nov 2020 20:27:02 +0000 (21:27 +0100)
committerArnout Engelen <arnout@bzzt.net>
Fri, 6 Nov 2020 13:52:48 +0000 (14:52 +0100)
With this parameter, docbook will generate the same id's when generating the
same docs. This is helpful to get bit-by-bit 'reproducible' output, which
makes auditing the package easier.

Tested both the cmake output and the automake output

doc/CMakeLists.txt
doc/Makefile.am

index 8239c8e863c20c976ee4435044a893434b76bf73..b7d020a88145be938f988b5d88347d59f4ad2027 100644 (file)
@@ -129,7 +129,7 @@ macro(DOCBOOK _sources _format)
     set(_outfile ${CMAKE_CURRENT_BINARY_DIR}/${_outname})
     add_custom_command(
         OUTPUT ${_outfile}
-        COMMAND ${XSLTPROC_EXECUTABLE} --output ${_outfile} --nonet --xinclude  --param passivetex.extensions '1' ${STYLESHEET} ${_infile}
+        COMMAND ${XSLTPROC_EXECUTABLE} --output ${_outfile} --nonet --xinclude  --param passivetex.extensions '1' --param generate.consistent.ids '1' ${STYLESHEET} ${_infile}
         DEPENDS ${XSLTPROC_EXECUTABLE} ${_infile}
         WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
     )
index b2a7b52ad94120de2a43e5bc82923183994b7802..47bca32e2c55d6fa7bb19797de98e5a47b28e03d 100644 (file)
@@ -84,7 +84,7 @@ if DBUS_XML_DOCS_ENABLED
 html_DATA += $(XMLTO_HTML)
 
 %.html: %.xml
-       $(XMLTO) html-nochunks $<
+       $(XMLTO) --stringparam generate.consistent.ids=1 html-nochunks $<
 
 %.1: %.1.xml
        $(XMLTO) man $<