From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ricardo Wurmus Subject: bug#22629: [PATCH v2 2/3] Add (guix describe) and use it to initialize '%package-search-path'. Date: Fri, 31 Aug 2018 16:32:43 +0200 Message-ID: <87d0ty1u9g.fsf@elephly.net> References: <87lg8nr1ab.fsf@gnu.org> <20180830213152.3404-1-ludo@gnu.org> <20180830213152.3404-2-ludo@gnu.org> <87k1o620c5.fsf@elephly.net> <87a7p2od0u.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:53050) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fvkUy-0006MZ-2O for bug-guix@gnu.org; Fri, 31 Aug 2018 10:34:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fvkUs-0004l9-OA for bug-guix@gnu.org; Fri, 31 Aug 2018 10:34:07 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:35733) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fvkUs-0004l1-Ie for bug-guix@gnu.org; Fri, 31 Aug 2018 10:34:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fvkUs-0005Eb-Bh for bug-guix@gnu.org; Fri, 31 Aug 2018 10:34:02 -0400 Sender: "Debbugs-submit" Resent-Message-ID: In-reply-to: <87a7p2od0u.fsf@gnu.org> List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: "bug-Guix" To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 22629@debbugs.gnu.org Ludovic Court=C3=A8s writes: > Regarding %package-module-path itself, whether channels come first or > not doesn=E2=80=99t actually make much of a difference at this point since > =E2=80=98fold-packages=E2=80=99 traverses everything anyway. Maybe in th= e future > =E2=80=98fold-packages=E2=80=99 could make some distinction though. Dunn= o. Ah, I see. Thanks for clarifying. >> I don=E2=80=99t know=E2=80=A6 there=E2=80=99s something about this file = system traversal that >> doesn=E2=80=99t sit right with me. I=E2=80=99m not sure about (command-= line) =E2=80=94 when >> =E2=80=A6/bin/guix is executed by a wrapper, will the wrapper be the =E2= =80=9Cprogram=E2=80=9D >> that we match against or the target? (This is a concern for wrappers >> that set up site-wide default channels or a remote daemon, for example.) > > The =E2=80=98guix=E2=80=99 command is a script starting with: > > #!/gnu/store/=E2=80=A6-guile-2.2.4/bin/guile --no-auto-compile > > =E2=80=98guile=E2=80=99 receives the =E2=80=98guix=E2=80=99 file name as = its argv[1]. Since the =E2=80=98guix=E2=80=99 > file name was passed as the first argument to =E2=80=98execve=E2=80=99, i= t is > necessarily valid (either it=E2=80=99s relative to $PWD or, in the likely= case > where =E2=80=98guix=E2=80=99 was searched for in $PATH, it=E2=80=99s an a= bsolute file name.) > > In addition (ice-9 command-line) arranges to make the first non-hyphen > argument the first element of what =E2=80=98command-line=E2=80=99 returns. > > If you have a wrapper that execs =E2=80=98guix=E2=80=99 or whatever, it= =E2=80=99ll still work. That=E2=80=99s good. > Of course, the trick doesn=E2=80=99t work if you do things like: > > guile -L ~/.config/guix/current/share/guile/site/2.2 > > but I think that=E2=80=99s OK. Yeah, I wouldn=E2=80=99t worry about that. Thanks! --=20 Ricardo