all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Mark H Weaver <mhw@netris.org>
To: greenfork.lists@yandex.com, 47786@debbugs.gnu.org
Subject: bug#47786: Several build --keep-failed result in wrong env variables
Date: Thu, 15 Apr 2021 16:24:34 -0400	[thread overview]
Message-ID: <875z0ni9cy.fsf@netris.org> (raw)
In-Reply-To: <87r1jc5ld1.fsf@yandex.com>

tags 47786 + notabug
close 47786
thanks

Hi Dmitry,

Dmitry Matveyev <greenfork.lists@yandex.com> writes:

> I use guix on Arch Linux, version
> 050be36cbf3a42199f64f2e44c59f1cb1b3afab5.
>
> Several invocations of guix build --keep-failed creates directories in
> /tmp like this one guix-build-hello-2.10.drv-0 for 1st build and then
> guix-build-hello-2.10.drv-1 for 2nd and so on (with last digit
> increasing). But environment variables for all of them are set to point
> to the very 1st directory.

This is the intended behavior, although I agree that it can be
surprising.

The environment variables refer to "/tmp/guix-build-….drv-0" because
within the build container, the directory is _always_ named
"/tmp/guix-build-….drv-0", regardless of what name was given to the
directory outside of the build container.

In general, where practical, we try to isolate the build container from
irrelevant details about the host system (such as the contents of /tmp),
because those details might leak into the build outputs, compromising
reproducibility.

For example, some packages retain the absolute file name of the build
directory, as an aid to developers when users report bugs.
Reproducibility of such package builds would be lost if the build
directory name varied depending on the contents on /tmp on the host
system.

Does that make sense?

Thanks for the report,

      Mark




  parent reply	other threads:[~2021-04-15 20:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-15  2:31 bug#47786: Several build --keep-failed result in wrong env variables Dmitry Matveyev
2021-04-15 17:06 ` Leo Famulari
2021-04-15 20:24 ` Mark H Weaver [this message]
2021-04-16  4:49   ` Dmitry Matveyev

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=875z0ni9cy.fsf@netris.org \
    --to=mhw@netris.org \
    --cc=47786@debbugs.gnu.org \
    --cc=greenfork.lists@yandex.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.