From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ricardo Wurmus Subject: bug#40039: 'wrap-script' introduces spurious argument Date: Sun, 22 Mar 2020 11:27:30 +0100 Message-ID: <87pnd4lm5p.fsf@elephly.net> References: <87k13psl82.fsf@inria.fr> <2969f516-ca88-ffa6-dd65-f6a29682d42c@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:34565) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jFxps-0002n1-1X for bug-guix@gnu.org; Sun, 22 Mar 2020 06:28:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jFxpr-0003YT-1O for bug-guix@gnu.org; Sun, 22 Mar 2020 06:28:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:42636) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jFxpq-0003Y3-Lt for bug-guix@gnu.org; Sun, 22 Mar 2020 06:28:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jFxpq-0005P8-GG for bug-guix@gnu.org; Sun, 22 Mar 2020 06:28:02 -0400 Sender: "Debbugs-submit" Resent-Message-ID: In-reply-to: <2969f516-ca88-ffa6-dd65-f6a29682d42c@gmail.com> 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-mx.org@gnu.org Sender: "bug-Guix" To: Brendan Tildesley Cc: 40039@debbugs.gnu.org Brendan Tildesley writes: > It appears the repeated (car cl) results in the executable path > getting sent to it's self as the first argument. I'm not sure how > things managed to work up until now? I tested the following change and > it fixed the one case I was using, but am not sure it is correct. why > was the cons (car cl) there in the first place? See the documentation of execl: -- Scheme Procedure: execl filename arg ... -- C Function: scm_execl (filename, args) Executes the file named by FILENAME as a new process image. The remaining arguments are supplied to the process; from a C program they are accessible as the =E2=80=98argv=E2=80=99 argument to =E2=80= =98main=E2=80=99. Conventionally the first ARG is the same as FILENAME. All arguments must be strings. If ARG is missing, FILENAME is executed with a null argument list, which may have system-dependent side-effects. This procedure is currently implemented using the =E2=80=98execv=E2=80= =99 system call, but we call it =E2=80=98execl=E2=80=99 because of its Scheme cal= ling interface. --=20 Ricardo