From dc995fcd5a62496721757f4ecb7f9b9d65399b5c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Tue, 10 Dec 2019 15:54:37 +0100 Subject: pack: Clarify the /bin/sh requirement for Singularity. * guix/scripts/pack.scm (squashfs-image)[symlinks*]: New variable. [build]: Use it instead of SYMLINKS. (guix-pack): Emit a warning and a hint when "bash" and "bash-minimal" are missing and PACK-FORMAT is 'squashfs. * doc/guix.texi (Invoking guix pack): Document the /bin/sh requirement for Singularity. --- doc/guix.texi | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) (limited to 'doc') diff --git a/doc/guix.texi b/doc/guix.texi index 3f646cd2ca..25efba118f 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -5053,7 +5053,7 @@ Yet another option is to produce a SquashFS image with the following command: @example -guix pack -f squashfs guile emacs geiser +guix pack -f squashfs bash guile emacs geiser @end example @noindent @@ -5088,6 +5088,21 @@ package names passed on the command line or in the manifest file. This produces a SquashFS image containing all the specified binaries and symlinks, as well as empty mount points for virtual file systems like procfs. + +@quotation Note +Singularity @emph{requires} you to provide @file{/bin/sh} in the image. +For that reason, @command{guix pack -f squashfs} always implies @code{-S +/bin=bin}. Thus, your @command{guix pack} invocation must always start +with something like: + +@example +guix pack -f squashfs bash @dots{} +@end example + +If you forget the @code{bash} (or similar) package, @command{singularity +run} and @command{singularity exec} will fail with an unhelpful ``no +such file or directory'' message. +@end quotation @end table @cindex relocatable binaries -- cgit v1.2.3