From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52473) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cyl0H-00077K-6y for guix-patches@gnu.org; Thu, 13 Apr 2017 16:06:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cyl0E-0000i0-Gy for guix-patches@gnu.org; Thu, 13 Apr 2017 16:06:05 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:47898) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cyl0E-0000hm-D8 for guix-patches@gnu.org; Thu, 13 Apr 2017 16:06:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1cyl0E-0006QU-5Q for guix-patches@gnu.org; Thu, 13 Apr 2017 16:06:02 -0400 Subject: bug#26166: [PATCH] gnu: cargo: Simplify unpacking. Resent-Message-ID: Date: Fri, 14 Apr 2017 00:20:52 +0200 From: Danny Milosavljevic Message-ID: <20170414002052.612ed7ae@scratchpost.org> In-Reply-To: <87pogosznr.fsf@gnu.org> References: <20170319002844.19407-1-dannym@scratchpost.org> <87pogosznr.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 26166@debbugs.gnu.org Hi Ludo, On Fri, 07 Apr 2017 22:58:32 +0200 ludo@gnu.org (Ludovic Court=C3=A8s) wrote: > It=E2=80=99s not immediately obvious that it=E2=80=99s a simplification. = ;-) Yeah well. Simple doesn't mean shorter. I think it's clearer to understan= d what it's doing when there a procedures that have names suggesting what i= t's for. :) > For clarity it may help to replace the =E2=80=98let=E2=80=99 with =E2=80= =9Cinternal defines=E2=80=9D, Done. > I don=E2=80=99t fully understand this file, but if it sounds good to you,= we > should apply it. Yeah, Rust stuff is definitely not straightforward. What this does is it sets up dependencies that are required to build cargo = - just like cargo-vendor (an extension of cargo) would have set them up. This avoids another bootstrapping problem (we would have to have cargo-vend= or binaries). But cargo-vendor is an entirely avoidable dependency because= the format of their package metadata is stable (and very minimal). The format of the metadata is stable because cargo-vendor is the official w= ay to bundle libraries with your custom project - we just bundle them on-th= e-fly to avoid bundling them in the cargo distribution file (like David's v= ersion did before) and previously having to distribute our own custom versi= on of cargo. cargo-vendor is a way that any developer on the world can use to bundle stu= ff for his Rust project *and check it into his git repository*. That means= that metadata is on git repos Mozilla doesn't control - which means the fo= rmat has to be stable (or at least backward-compatible). Now we replace cargo-vendor entirely. Both cargo-build-system and this car= go package do cargo-vendors job in Guile (that's what install-rust-library = does; now I wonder whether I should call it 'bundle-rust-library' instead. = WDYT?).