unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: "Ludovic Courtès" <ludo@gnu.org>
To: John Kehayias <john.kehayias@protonmail.com>
Cc: 58861@debbugs.gnu.org
Subject: bug#58861: guix shell emulate-fhs option can have wrong glibc package
Date: Wed, 02 Nov 2022 16:50:53 +0100	[thread overview]
Message-ID: <87sfj1tkwy.fsf@gnu.org> (raw)
In-Reply-To: <87tu3n9oxd.fsf@protonmail.com> (John Kehayias's message of "Sat,  29 Oct 2022 05:31:05 +0000")

Hi John,

John Kehayias <john.kehayias@protonmail.com> skribis:

> After commit <https://git.savannah.gnu.org/cgit/guix.git/commit/?id=c07b55eb94f8cfa9d0f56cfd97a16f2f7d842652> I noticed a changed in behavior of guix shell with the emulate-fhs option for a container. I tracked it down to the wrong glibc package appearing in the container, i.e. the standard Guix version rather than glibc-for-fhs (which reads a global ld cache).
>
> The cause I believe is related to <https://issues.guix.gnu.org/58859>, namely that package input order for a profile can matter. But it is slightly different here since the glibc-for-fhs package is added internally.
>
> We can see this demonstrated by comparing the FHS container with a -D input so that a glibc package is implicitly included (here from the gnu-build-system):
>
> ❯ guix shell -CFD hello coreutils
> john@narya ~/Files/UPenn/canvasgrading [env]$ ls /lib/ld* -la
> lrwxrwxrwx 1 65534 overflow 69 Jan  1  1970 /lib/ld-2.33.so -> /gnu/store/5h2w4qi9hk1qzzgi1w83220ydslinr4s-glibc-2.33/lib/ld-2.33.so
> lrwxrwxrwx 1 65534 overflow 79 Jan  1  1970 /lib/ld-linux-x86-64.so.2 -> /gnu/store/5h2w4qi9hk1qzzgi1w83220ydslinr4s-glibc-2.33/lib/ld-linux-x86-64.so.2

How about fixing it by moving the (alist-cons 'expression …) thing right
before the ‘options-with-caching’ call in ‘parse-args’?

That way it would no longer be sensitive to the position of ‘-F’ on the
command line.

Could you give it a try and add a test?

Thanks,
Ludo’.




  parent reply	other threads:[~2022-11-02 15:52 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-29  5:31 bug#58861: guix shell emulate-fhs option can have wrong glibc package John Kehayias via Bug reports for GNU Guix
2022-11-02 12:47 ` zimoun
2022-11-02 15:50   ` John Kehayias via Bug reports for GNU Guix
2022-11-02 15:50 ` Ludovic Courtès [this message]
2022-11-03 18:50   ` bug#58861: [PATCH] shell: Fix '--emulate-fhs' sometimes not including 'glibc-for-fhs' John Kehayias via Bug reports for GNU Guix
2022-11-06 11:18     ` 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

  List information: https://guix.gnu.org/

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

  git send-email \
    --in-reply-to=87sfj1tkwy.fsf@gnu.org \
    --to=ludo@gnu.org \
    --cc=58861@debbugs.gnu.org \
    --cc=john.kehayias@protonmail.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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).