From 1f91ecd3c06ac3275490311ec79bb8f361e9d963 Mon Sep 17 00:00:00 2001 From: John Kehayias Date: Sat, 6 Jan 2024 17:01:18 -0500 Subject: [PATCH] nonguix: multiarch-container: Set LD_LIBRARY_PATH inside container. Fixes #303. Previously LD_LIBRARY_PATH was being set before the container was launched, which could cause issues on some foreign distros where this alters what is loaded from an FHS structure. This was only meant to be set inside the container, though this didn't cause any issues on a Guix System. * nonguix/multiarch-container.scm (make-container-wrapper): Move setting LD_LIBRARY_PATH from here ... (make-internal-script): ... to here. --- nonguix/multiarch-container.scm | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/nonguix/multiarch-container.scm b/nonguix/multiarch-container.scm index 1462881..6cbd14a 100644 --- a/nonguix/multiarch-container.scm +++ b/nonguix/multiarch-container.scm @@ -338,10 +338,6 @@ in a sandboxed FHS environment." (args (cdr (command-line))) (command (if DEBUG '() `("--" ,run ,@args)))) - ;; Set this so that e.g. non-Steam games added to Steam will launch - ;; properly. It seems otherwise they don't make it to launching - ;; Steam's pressure-vessel container (for Proton games). - (setenv "LD_LIBRARY_PATH" "/lib64:/lib") ;; Set this so Steam's pressure-vessel container does not need to ;; generate locales, improving startup time. This needs to be set to ;; the "usual" path, probably so they are included in the @@ -526,6 +522,16 @@ application." ;; (previous would output this error but continue). (if (file-exists? ".steam/root/bootstrap.tar.xz") (chmod ".steam/root/bootstrap.tar.xz" #o644)) + ;; TODO: Should other environment setup also happen inside the + ;; container rather than before container is launched? + ;; + ;; Set this so that e.g. non-Steam games added to Steam will + ;; launch properly. It seems otherwise they don't make it to + ;; launching Steam's pressure-vessel container (for Proton + ;; games). Wait to set this inside the container to not cause + ;; issues on foreign distros, see + ;; + (setenv "LD_LIBRARY_PATH" "/lib64:/lib") ;; Process FHS-specific command line options. (let* ((options (getopt-long (or fhs-args '("")) fhs-option-spec))