File: tools-perf-man-date.patch

package info (click to toggle)
linux 4.19.249-2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 968,784 kB
  • sloc: ansic: 16,810,930; asm: 272,263; makefile: 38,450; sh: 33,900; perl: 27,702; python: 21,148; cpp: 5,068; yacc: 4,650; lex: 2,584; awk: 1,386; ruby: 25; sed: 5
file content (37 lines) | stat: -rw-r--r-- 1,268 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
From: Ben Hutchings <ben@decadent.org.uk>
Date: Mon, 13 Jul 2015 20:29:20 +0100
Subject: perf tools: Use $KBUILD_BUILD_TIMESTAMP as man page date
Forwarded: http://mid.gmane.org/20160517132809.GE7555@decadent.org.uk
    
This allows man pages to be built reproducibly.

Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
---
Index: linux/tools/perf/Documentation/Makefile
===================================================================
--- linux.orig/tools/perf/Documentation/Makefile
+++ linux/tools/perf/Documentation/Makefile
@@ -131,6 +131,9 @@ endif
 ifdef DOCBOOK_SUPPRESS_SP
 XMLTO_EXTRA += -m manpage-suppress-sp.xsl
 endif
+ifdef KBUILD_BUILD_TIMESTAMP
+ASCIIDOC_EXTRA += -a revdate=$(shell date -u -d '$(KBUILD_BUILD_TIMESTAMP)' +%Y-%m-%d)
+endif
 
 SHELL_PATH ?= $(SHELL)
 # Shell quote;
Index: linux/tools/perf/Documentation/asciidoc.conf
===================================================================
--- linux.orig/tools/perf/Documentation/asciidoc.conf
+++ linux/tools/perf/Documentation/asciidoc.conf
@@ -71,6 +71,9 @@ ifdef::backend-docbook[]
 [header]
 template::[header-declarations]
 <refentry>
+<refentryinfo>
+template::[docinfo]
+</refentryinfo>
 <refmeta>
 <refentrytitle>{mantitle}</refentrytitle>
 <manvolnum>{manvolnum}</manvolnum>