]> git.proxmox.com Git - pve-kernel.git/blame - uname-version-timestamp.patch
initial import from https://git.proxmox.com/?p=pve-kernel.git;a=tree
[pve-kernel.git] / uname-version-timestamp.patch
CommitLineData
ba2f1a67
FG
1From: Ben Hutchings <ben@decadent.org.uk>
2Subject: Make mkcompile_h accept an alternate timestamp string
3Date: Tue, 12 May 2015 19:29:22 +0100
4Forwarded: not-needed
5
6We want to include the Debian version in the utsname::version string
7instead of a full timestamp string. However, we still need to provide
8a standard timestamp string for gen_initramfs_list.sh to make the
9kernel image reproducible.
10
11Make mkcompile_h use $KBUILD_BUILD_VERSION_TIMESTAMP in preference to
12$KBUILD_BUILD_TIMESTAMP.
13
14--- a/scripts/mkcompile_h
15+++ b/scripts/mkcompile_h
16@@ -37,10 +37,14 @@ else
17 VERSION=$KBUILD_BUILD_VERSION
18 fi
19
20-if [ -z "$KBUILD_BUILD_TIMESTAMP" ]; then
21- TIMESTAMP=`date`
22+if [ -z "$KBUILD_BUILD_VERSION_TIMESTAMP" ]; then
23+ if [ -z "$KBUILD_BUILD_TIMESTAMP" ]; then
24+ TIMESTAMP=`date`
25+ else
26+ TIMESTAMP=$KBUILD_BUILD_TIMESTAMP
27+ fi
28 else
29- TIMESTAMP=$KBUILD_BUILD_TIMESTAMP
30+ TIMESTAMP=$KBUILD_BUILD_VERSION_TIMESTAMP
31 fi
32 if test -z "$KBUILD_BUILD_USER"; then
33 LINUX_COMPILE_BY=$(whoami | sed 's/\\/\\\\/')