diff options
Diffstat (limited to 'gnu/packages')
-rw-r--r-- | gnu/packages/mono.scm | 11 | ||||
-rw-r--r-- | gnu/packages/patches/mono-mdoc-timestamping.patch | 15 |
2 files changed, 25 insertions, 1 deletions
diff --git a/gnu/packages/mono.scm b/gnu/packages/mono.scm index 8ab449dd8e..17f90fe30a 100644 --- a/gnu/packages/mono.scm +++ b/gnu/packages/mono.scm @@ -41,7 +41,8 @@ ".tar.bz2")) (sha256 (base32 - "0jibyvyv2jy8dq5ij0j00iq3v74r0y90dcjc3dkspcfbnn37cphn")))) + "0jibyvyv2jy8dq5ij0j00iq3v74r0y90dcjc3dkspcfbnn37cphn")) + (patches (search-patches "mono-mdoc-timestamping.patch")))) (build-system gnu-build-system) (native-inputs `(("gettext" ,gettext-minimal) @@ -52,10 +53,18 @@ (arguments `(#:phases (modify-phases %standard-phases + (add-after 'unpack 'make-reproducible + (lambda _ + (substitute* "mono/mini/Makefile.in" + (("build_date = [^;]*;") + "build_date = (void*) 0;")) + #t)) (add-after 'unpack 'set-env (lambda _ ;;* (#:key inputs #:allow-other-keys) ;; all tests under mcs/class fail trying to access $HOME (setenv "HOME" "/tmp") + ;; ZIP files have "DOS time" which starts in Jan 1980. + (setenv "SOURCE_DATE_EPOCH" "315532800") #t)) (add-after 'unpack 'fix-includes (lambda _ diff --git a/gnu/packages/patches/mono-mdoc-timestamping.patch b/gnu/packages/patches/mono-mdoc-timestamping.patch new file mode 100644 index 0000000000..d5191a93eb --- /dev/null +++ b/gnu/packages/patches/mono-mdoc-timestamping.patch @@ -0,0 +1,15 @@ +--- mono-4.4.1/mcs/class/monodoc/Monodoc/storage/ZipStorage.cs.orig 2018-11-26 22:16:25.008879747 +0100 ++++ mono-4.4.1/mcs/class/monodoc/Monodoc/storage/ZipStorage.cs 2018-11-26 22:21:53.969770985 +0100 +@@ -74,6 +74,12 @@ + id = GetNewCode (); + + ZipEntry entry = new ZipEntry (id); ++ var SOURCE_DATE_EPOCH_string = Environment.GetEnvironmentVariable("SOURCE_DATE_EPOCH"); ++ if (SOURCE_DATE_EPOCH_string != null) ++ { ++ var SOURCE_DATE_EPOCH = Convert.ToInt64(SOURCE_DATE_EPOCH_string); ++ entry.DateTime = new DateTime(SOURCE_DATE_EPOCH, DateTimeKind.Utc); ++ } + zipOutput.PutNextEntry (entry); + } + |