all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: ludo@gnu.org (Ludovic Courtès)
To: Danny Milosavljevic <dannym@scratchpost.org>
Cc: guix-devel@gnu.org
Subject: Re: Differences between container used by "guix build" and "guix environment -C -N"
Date: Mon, 19 Jun 2017 10:21:33 +0200	[thread overview]
Message-ID: <87k2481j76.fsf@gnu.org> (raw)
In-Reply-To: <20170618144350.67710ce2@scratchpost.org> (Danny Milosavljevic's message of "Sun, 18 Jun 2017 14:43:50 +0200")

Hello,

Danny Milosavljevic <dannym@scratchpost.org> skribis:

> I'm trying to track down the test_process_mask problem in Guix when trying to test rustc.
>
> For that I did:
>
> (apply attached patch)
> $ guix build --keep-failed rustc # will fail
> $ cd /tmp/guix-build-rustc-1.16.0.drv-0
> $ guix environment -C -N rustc
> $ bash
> $ source environment-variables
> $ cd rustc-1.16.0-src
> $ ./x86_64-unknown-linux-gnu/stage2/test/stdtest-x86_64-unknown-linux-gnu 2>&1 |grep test_process_mask
>
> will not fail.
>
> Why does it fail in "guix build", then?

What does the test do?

I tried to document the differences between the container the daemon
creates and the one you get with “guix environment -C” here:

  https://www.gnu.org/software/guix/manual/html_node/Debugging-Build-Failures.html

Essentially it boils down to /bin/sh available in one case and not in
the other, and UID being zero in one case and something else in the
other.  If you add “-N”, then of course you have networking, which is
not available in the guix-daemon container.

In the end, if you want to be sure what the differences are, you can
compare:

  https://git.savannah.gnu.org/cgit/guix.git/tree/nix/libstore/build.cc#n2062
  and
  https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/build/linux-container.scm#n209

Hopefully with reepca’s work we can eventually have a single
implementation.  :-)

HTH!

Ludo’.

  reply	other threads:[~2017-06-19  8:21 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-18 12:43 Differences between container used by "guix build" and "guix environment -C -N" Danny Milosavljevic
2017-06-19  8:21 ` Ludovic Courtès [this message]
2017-06-19 18:58 ` Danny Milosavljevic
2017-07-01 12:59   ` Ludovic Courtès

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=87k2481j76.fsf@gnu.org \
    --to=ludo@gnu.org \
    --cc=dannym@scratchpost.org \
    --cc=guix-devel@gnu.org \
    /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.