From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:42602) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1isoFk-00013j-Js for guix-patches@gnu.org; Sat, 18 Jan 2020 08:35:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1isoFi-0003mh-73 for guix-patches@gnu.org; Sat, 18 Jan 2020 08:35:04 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:34697) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1isoFi-0003md-39 for guix-patches@gnu.org; Sat, 18 Jan 2020 08:35:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1isoFi-000747-0e for guix-patches@gnu.org; Sat, 18 Jan 2020 08:35:02 -0500 Subject: [bug#38546] [PATCH 02/11] gnu: julia: use SOURCE_DATE_EPOCH for precompilation timestamp References: <87v9qpvbyr.fsf@guixSD.i-did-not-set--mail-host-address--so-tickle-me> In-Reply-To: <87v9qpvbyr.fsf@guixSD.i-did-not-set--mail-host-address--so-tickle-me> Resent-Message-ID: From: nixo Date: Sat, 18 Jan 2020 13:58:37 +0100 Message-ID: <87o8v0vqfw.fsf@guixSD.i-did-not-set--mail-host-address--so-tickle-me> MIME-Version: 1.0 Content-Type: text/plain List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: 38546@debbugs.gnu.org * gnu/packages/patches/julia-fake-mtime-with-SOURCE_DATE_EPOCH.patch: new file --- gnu/local.mk | 1 + gnu/packages/julia.scm | 4 ++- ...ia-fake-mtime-with-SOURCE_DATE_EPOCH.patch | 29 +++++++++++++++++++ 3 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/julia-fake-mtime-with-SOURCE_DATE_EPOCH.patch diff --git a/gnu/local.mk b/gnu/local.mk index 00ff3b8d61..fe8634b44d 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1010,6 +1010,7 @@ dist_patch_DATA = \ %D%/packages/patches/java-xerces-bootclasspath.patch \ %D%/packages/patches/java-xerces-build_dont_unzip.patch \ %D%/packages/patches/java-xerces-xjavac_taskdef.patch \ + %D%/packages/patches/julia-SOURCE_DATE_EPOCH-mtime.patch \ %D%/packages/patches/jbig2dec-ignore-testtest.patch \ %D%/packages/patches/kdbusaddons-kinit-file-name.patch \ %D%/packages/patches/libvirt-create-machine-cgroup.patch \ diff --git a/gnu/packages/julia.scm b/gnu/packages/julia.scm index e4db39afbd..a66309b611 100644 --- a/gnu/packages/julia.scm +++ b/gnu/packages/julia.scm @@ -191,7 +191,9 @@ version "/julia-" version ".tar.gz")) (sha256 (base32 - "1nwkmr9j55g1zkxdchnid1h022s0is52vx23niksshgvh793g41x")))) + "1nwkmr9j55g1zkxdchnid1h022s0is52vx23niksshgvh793g41x")) + (patches + (search-patches "julia-fake-mtime-with-SOURCE_DATE_EPOCH.patch")))) (build-system gnu-build-system) (arguments `(#:test-target "test" diff --git a/gnu/packages/patches/julia-fake-mtime-with-SOURCE_DATE_EPOCH.patch b/gnu/packages/patches/julia-fake-mtime-with-SOURCE_DATE_EPOCH.patch new file mode 100644 index 0000000000..467e6d68d1 --- /dev/null +++ b/gnu/packages/patches/julia-fake-mtime-with-SOURCE_DATE_EPOCH.patch @@ -0,0 +1,29 @@ +From e4dc28db1d70819505fd1a68fd9d2bfc4fb61a7d Mon Sep 17 00:00:00 2001 +From: nixo +Date: Fri, 17 Jan 2020 11:28:30 +0100 +Subject: [PATCH] base: loading: support fake mtime with SOURCE_DATE_EPCOCH + +Do this when loading libraries +--- + base/loading.jl | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +diff --git a/base/loading.jl b/base/loading.jl +index 7f11a2d4fc..1b4686d1dc 100644 +--- a/base/loading.jl ++++ b/base/loading.jl +@@ -807,7 +807,10 @@ function _include_dependency(mod::Module, _path::AbstractString) + path = normpath(joinpath(dirname(prev), _path)) + end + if _track_dependencies[] +- push!(_require_dependencies, (mod, path, mtime(path))) ++ push!(_require_dependencies, ++ (mod, path, ++ haskey(ENV, "SOURCE_DATE_EPOCH") ? ++ parse(Float64, ENV["SOURCE_DATE_EPOCH"]) : mtime(path))) + end + return path, prev + end +-- +2.24.1 + -- 2.24.1