From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: [PATCH 1/3] build/utils: Add `wrap-language-programs`. Date: Sat, 19 Nov 2016 00:07:57 +0100 Message-ID: <87vavk4caa.fsf@gnu.org> References: <20161116132734.5943-1-alex@pompo.co> <20161116132734.5943-2-alex@pompo.co> 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]:57837) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1c7sGP-00006u-7i for guix-devel@gnu.org; Fri, 18 Nov 2016 18:08:10 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1c7sGO-0003uQ-DS for guix-devel@gnu.org; Fri, 18 Nov 2016 18:08:09 -0500 In-Reply-To: <20161116132734.5943-2-alex@pompo.co> (Alex Sassmannshausen's message of "Wed, 16 Nov 2016 14:27:32 +0100") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Alex Sassmannshausen Cc: guix-devel@gnu.org, Alex Sassmannshausen Hey! Alex Sassmannshausen skribis: > * guix/build/utils.scm (wrap-language-programs): New procedure. Neat! > +(define (wrap-language-programs path-proc env-var) Maybe =E2=80=98program-wrapper=E2=80=99 or =E2=80=98program-wrapping-proced= ure=E2=80=99 or =E2=80=98program-wrapping-phase=E2=80=99 to suggest that it returns a proce= dure? (I=E2=80=99m not sure =E2=80=9Clanguage=E2=80=9D is helpful.) > + "Return a procedure, which, invoked as part of a `wrap' phase, is capa= ble of > +wrapping executables inside an environment in which ENV-VAR is correctly= set. > + > +The string ENV-VAR is the name of the environmental variable we are sett= ing > +for the executable we are wrapping. PATH-PROC is a procedure of 2 argum= ents, > +`inputs' and `outputs', returning the value that we should send ENV-VAR = to. > + > +This is a specialized version of `wrap-program' below, intended specific= ally > +to grant all executables that are part of our output access to all libra= ries > +that were declared in our inputs. This is of use for languages such as = Perl, > +Python and Guile." Nitpick: the GCS now recommend straight quotes in ASCII, like 'this'. :-) Otherwise this and the 2 subsequent patches LGTM. Could you make sure that the resulting wrapper is the same, either by rebuilding one way or another as discussed earlier, or by running the code =E2=80=9Cby hand=E2=80=9D on an example, maybe in =E2=80=98guix enviro= nment=E2=80=99? After that you could commit in =E2=80=98core-updates=E2=80=99. Thank you! Ludo=E2=80=99.