all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Maxime Devos <maximedevos@telenet.be>
To: 62547@debbugs.gnu.org
Subject: bug#62547: --symlink option of "guix shell -C -F" is non-functional for /lib and /usr/lib, unlike /bin
Date: Thu, 30 Mar 2023 19:44:32 +0200	[thread overview]
Message-ID: <f7f4118a-a4de-a985-3e3d-a97fc71df10e@telenet.be> (raw)


[-- Attachment #1.1.1: Type: text/plain, Size: 1986 bytes --]

$ guix shell -F -C tk -- some-software
# ... libtk8.5 not found, let's choose version 8.5

$ LC_ALL=en_GB.UTF-8 guix shell -F -C tk@8.5 shell
guix shell: error: tk: package not found for version 8.5

# Guix doesn't have version 8.5.  Let's lie and pretend
# that 8.5=8.6, maybe it will be ‘close enough’ for
# ‘some-software’.

$ guix shell -F -C tk --symlink=/lib/libtk8.5.so=/lib/libtk8.5.so -- 
some-software

guix shell: fout: symlink target is absolute: '/lib/libtk8.5.so'

tip: The target of the symlink must be relative rather than absolute, as 
it is relative to the profile created.
Perhaps the source and target components of the symlink spec were 
inverted? Below is a valid example, where the
`/usr/bin/env' symbolic link is to target the profile's `bin/env' file:

      --symlink=/usr/bin/env=bin/env

# Looks an arbitrary limitation to me -- the symlink code could just
# treat absolute targets as absolute instead of relative to the profile.
# Still, let's give following the tip a try.

$ LC_ALL=en_GB.UTF-8 guix shell -F -C tk 
--symlink=/lib/libtk8.5.so=lib/libtk8.6.so -- some-software
error: failed to evaluate directive: ("/lib/libtk8.5.so" -> 
"/gnu/store/sbvf4784c43ssr20x45icvm8s8h7zvh4-profile/lib/libtk8.6.so")
guix shell: error: symlink: Read-only file system: ".//lib/libtk8.5.so"


# If /usr/lib is tried instead of /lib, a different error occurs:

$ LC_ALL=en_GB.UTF-8 guix shell -F -C tk 
--symlink=/usr/lib/libtk8.5.so=lib/libtk8.6.so -- some-software

guix shell: error: symlink: File exists: "/usr/lib"

# Contrast this with /bin, in which files symlinks can be put, unlike
# /usr/lib and /lib (yes I know that putting libraries in /bin doesn't
# make much sense, it's just an example):

$ LC_ALL=en_GB.UTF-8 guix shell -F -C tk 
--symlink=/bin/libtk8.5.so=lib/libtk8.6.so -- some-software
guix shell: error: some-software: command not found
hint: Did you mean 'mtrace'?

Greetings,
Maxime.

[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 929 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 236 bytes --]

                 reply	other threads:[~2023-03-30 17:45 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=f7f4118a-a4de-a985-3e3d-a97fc71df10e@telenet.be \
    --to=maximedevos@telenet.be \
    --cc=62547@debbugs.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.