From mboxrd@z Thu Jan 1 00:00:00 1970 From: Subject: bug#37035: --with-graft tries to download source files and build them Date: Sun, 18 Aug 2019 06:55:08 +0100 (BST) Message-ID: References: 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]:60536) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1hzEAd-0006Am-JV for bug-guix@gnu.org; Sun, 18 Aug 2019 01:56:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hzEAc-00080i-H9 for bug-guix@gnu.org; Sun, 18 Aug 2019 01:56:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:48463) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hzEAc-00080Y-3B for bug-guix@gnu.org; Sun, 18 Aug 2019 01:56:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hzEAc-00030z-1I for bug-guix@gnu.org; Sun, 18 Aug 2019 01:56:02 -0400 Sender: "Debbugs-submit" Resent-Message-ID: Content-Disposition: inline In-Reply-To: <87zhkafd56.fsf@netris.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: Mark H Weaver Cc: 37035 <37035@debbugs.gnu.org> Hi, > You asked Guix to build something, so it's not surprising to me that it > might need to download some source code to do that. >=20 > Can you spell out more clearly what you expected to happen differently, > and why you think Guix is acting improperly here? >=20 > Thanks, > Mark Originally I expected it to attempt to graft mesa onto the love package, ev= en though it's the exact same input, however after running `guix build --dr= y-run --with-graft=3Dsubversion=3Dsubversion git` I see that it shouldn't o= utput anything (same as running `guix build` with a package you already hav= e all substitutes for). If I run `guix build --dry-run love` it shows that it will just download th= e substitute for "love", not build anything else from source, so grafting m= esa onto it (even though it's the same input) shouldn't try to build anythi= ng from source. Also just to note, in this example grafting "mesa" onto itself is just as a= n example, not for a useful reason. An example that doesn't try to build an= ything is running `guix build --dry-run --with-graft=3Dsubversion=3Dsubvers= ion git`. As an example of a graft that works, if you put this in a file and build it= with `guix build -f `, it will successfully graft the "hello" packag= e (with the name and version changed) onto the "git" package: ``` (use-modules (guix packages) (gnu packages base) (gnu packages version-cont= rol)) (define new-subversion (package (inherit hello) (name "subversion") (version (package-version subversion)))) (define new-subversion-graft (package (inherit subversion) (replacement new-subversion))) (define with-new-subversion (package-input-rewriting `((,subversion . ,new-subversion-graft)))) (with-new-subversion git) ``` You can see that it worked by running `/gnu/store/...-git-2.22.0-svn/libexe= c/git-core/git-svn`, and it will fail with a bunch of errors, unlike the un= grafted package.=