From unknown Mon Aug 11 21:14:18 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#72291 <72291@debbugs.gnu.org> To: bug#72291 <72291@debbugs.gnu.org> Subject: Status: =?UTF-8?Q?=E2=80=98guix?= pack =?UTF-8?Q?-RR=E2=80=99_?= =?UTF-8?Q?doesn=E2=80=99t?= support provide =?UTF-8?Q?=E2=80=9Cfakechroot=E2=80=9D?= engine for script Reply-To: bug#72291 <72291@debbugs.gnu.org> Date: Tue, 12 Aug 2025 04:14:18 +0000 retitle 72291 =E2=80=98guix pack -RR=E2=80=99 doesn=E2=80=99t support provi= de =E2=80=9Cfakechroot=E2=80=9D engine for script reassign 72291 guix submitter 72291 Ludovic Court=C3=A8s severity 72291 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Thu Jul 25 11:05:48 2024 Received: (at submit) by debbugs.gnu.org; 25 Jul 2024 15:05:48 +0000 Received: from localhost ([127.0.0.1]:37575 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sX02N-0006hn-PD for submit@debbugs.gnu.org; Thu, 25 Jul 2024 11:05:48 -0400 Received: from lists.gnu.org ([209.51.188.17]:36166) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sX02M-0006hf-8v for submit@debbugs.gnu.org; Thu, 25 Jul 2024 11:05:46 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sX028-0003oW-Ac for bug-guix@gnu.org; Thu, 25 Jul 2024 11:05:34 -0400 Received: from mail3-relais-sop.national.inria.fr ([192.134.164.104]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sX023-0005Xn-QC for bug-guix@gnu.org; Thu, 25 Jul 2024 11:05:31 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=inria.fr; s=dc; h=from:to:subject:date:message-id:mime-version: content-transfer-encoding; bh=J2mWPiqSCTI+K6FlIm59JnH95ypqWvXotNpFhdJhBA8=; b=DMM7x4JvM1wJtyYyafBO0HEpPLm5yv5uD5d80ImDbRJM7jqafqi+X8/z 4zuS5E1xj6fbDPQh3wdO5OuKGkd0nAcMyiZOSbfuw2TcaSnFd9PeA2U36 utL3trkjjOjTEgkR+hyXdB1q2zvn7tyRx3Gv/WSsmIzlYVYDywq4wD5ly s=; Authentication-Results: mail3-relais-sop.national.inria.fr; dkim=none (message not signed) header.i=none; spf=SoftFail smtp.mailfrom=ludovic.courtes@inria.fr; dmarc=fail (p=none dis=none) d=inria.fr X-IronPort-AV: E=Sophos;i="6.09,236,1716242400"; d="scan'208";a="92964584" Received: from unknown (HELO ribbon) ([193.50.110.239]) by mail3-relais-sop.national.inria.fr with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Jul 2024 17:05:20 +0200 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: bug-guix@gnu.org Subject: =?utf-8?Q?=E2=80=98guix?= pack =?utf-8?B?LVJS4oCZIGRvZXNu4oCZdA==?= support provide =?utf-8?B?4oCcZmFrZWNocm9vdOKAnQ==?= engine for script X-Debbugs-Cc: Romain GARBAGE X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: Octidi 8 Thermidor an 232 de la =?utf-8?Q?R=C3=A9vol?= =?utf-8?Q?ution=2C?= jour du Carthame X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Thu, 25 Jul 2024 17:05:19 +0200 Message-ID: <87y15pcy1c.fsf@inria.fr> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=192.134.164.104; envelope-from=ludovic.courtes@inria.fr; helo=mail3-relais-sop.national.inria.fr X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) Assume a manifest like this: --8<---------------cut here---------------start------------->8--- (use-modules (guix)) (define program (program-file "hello" #~(display "hello"))) (define package-tree (computed-file "package-with-script" #~(let ((bin (string-append #$output "/bin"))) (mkdir #$output) (mkdir bin) (copy-file #$program (string-append bin "/hello"))))) (manifest (list (manifest-entry (name "hello") (version "0") (item package-tree)))) --8<---------------cut here---------------end--------------->8--- Passing it to =E2=80=98guix pack -RR -m=E2=80=99 yields a bundle where the = =E2=80=9Cfakechroot=E2=80=9D execution engine is not supported for the =E2=80=98bin/hello=E2=80=99 scrip= t. The explanation is in a TODO in (guix scripts pack): (define (elf-loader-compile-flags program) ;; Return the cpp flags defining macros for the ld.so/fakechroot ;; wrapper of PROGRAM. #$(if fakechroot? ;; TODO: Handle scripts by wrapping their interpreter. #~(if (elf-file? program) =E2=80=A6 '()) #~'())) I=E2=80=99m not entirely sure how to address it. One workaround is to add =E2=80=98bash-minimal=E2=80=99 to the pack: guix pack -RR bash-minimal =E2=80=A6 =E2=80=A6 and then, on the target machine, to run Bash first: GUIX_EXECUTION_ENGINE=3Dfakechroot ./bin/sh -c ./bin/the-script Ludo=E2=80=99.