From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:58641) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1igbjC-0004Qn-VZ for guix-patches@gnu.org; Sun, 15 Dec 2019 16:47:03 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1igbjB-0006f8-VQ for guix-patches@gnu.org; Sun, 15 Dec 2019 16:47:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:59589) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1igbjB-0006cQ-RT for guix-patches@gnu.org; Sun, 15 Dec 2019 16:47:01 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1igbjB-0001TB-PB for guix-patches@gnu.org; Sun, 15 Dec 2019 16:47:01 -0500 Subject: [bug#38546] [PATCH 2/3] gnu: julia-build-system: Enable tests. Resent-Message-ID: From: Ludovic =?UTF-8?Q?Court=C3=A8s?= References: <87v9qpvbyr.fsf@guixSD.i-did-not-set--mail-host-address--so-tickle-me> <87sgltvbs1.fsf@guixSD.i-did-not-set--mail-host-address--so-tickle-me> Date: Sun, 15 Dec 2019 22:45:53 +0100 In-Reply-To: <87sgltvbs1.fsf@guixSD.i-did-not-set--mail-host-address--so-tickle-me> ("=?UTF-8?Q?Nicol=C3=B2?= Balzarotti"'s message of "Thu, 10 Oct 2019 17:49:15 +0200") Message-ID: <877e2xs1ny.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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: =?UTF-8?Q?Nicol=C3=B2?= Balzarotti Cc: Guix Patches <38546@debbugs.gnu.org> Nicol=C3=B2 Balzarotti skribis: > --- > guix/build-system/julia.scm | 4 +++- > guix/build/julia-build-system.scm | 28 +++++++++++++++++++--------- > 2 files changed, 22 insertions(+), 10 deletions(-) With a commit log, please. :-) > --- a/guix/build/julia-build-system.scm > +++ b/guix/build/julia-build-system.scm > @@ -32,7 +32,13 @@ > ;; Code: >=20=20 > (define (invoke-julia code) > - (invoke "julia" "-e" code)) > + ;; Julia stores the result of the time() call > + ;; inside the precompiled file. When trying to load it, its precompila= tion > + ;; it fails at comparing the file mtime with the precompilation time, > + ;; always triggering a recompile. This fixes the stored value. > + ;; Also, libc.jl rand() uses time() as its seed. This might introduce = indeterminism while building > + ;; Default guix mtime is 1, so I'm setting the same here (if they diff= er, precompilation is invalid) > + (invoke "faketime" "-f" "1970-01-01 00:00:01" "julia" "-e" code)) Do you think it would be feasible to modify Julia to emit this fixed timestamp, or to honor SOURCE_DATE_EPOCH, instead of using =E2=80=98faketim= e=E2=80=99? The reason I=E2=80=99m asking is that (1) =E2=80=98faketime=E2=80=99 relies= on LD_PRELOAD and so it could introduce its own set of issues, and (2) I wouldn=E2=80=99t be surprised to find ready-to-use SOURCE_DATE_EPOCH patches from fellow Reproducible Builders floating around. :-) Ludo=E2=80=99.