linux kernel determinism: unify timestamp style

Testing showed the linux build is sensitive to /usr/include/ncursesw
unless chrooted (on non-nixos).
On a single chrooted nixos machine, -A linux is binary reproducible.

CC #2281 & @alexanderkjeldaas.
This commit is contained in:
Vladimír Čunát 2015-01-03 12:29:52 +01:00
parent c510f3da49
commit 6671aff83e
2 changed files with 4 additions and 2 deletions

View File

@ -57,7 +57,10 @@ let
autoModules = stdenv.platform.kernelAutoModules;
arch = stdenv.platform.kernelArch;
KBUILD_BUILD_TIMESTAMP = 1; # (time_t)1
preConfigure = ''
buildFlagsArray+=("KBUILD_BUILD_TIMESTAMP=Thu Jan 1 00:00:01 UTC 1970")
'';
crossAttrs = let
cp = stdenv.cross.platform;
in {

View File

@ -105,7 +105,6 @@ let
'';
buildFlags = [
"KBUILD_BUILD_TIMESTAMP=1" # (time_t)1
"KBUILD_BUILD_VERSION=1-NixOS"
platform.kernelTarget
] ++ optional isModular "modules";