From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mark H Weaver Subject: bug#35012: Can't install icecat Date: Sat, 30 Mar 2019 02:14:14 -0400 Message-ID: <8736n4anxq.fsf@netris.org> References: <87mule7883.fsf@netris.org> <87a7he2rk5.fsf@posteo.mx> <20190329102005.3623fd57@alma-ubu> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([209.51.188.92]:40558) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hA7Hj-0004s3-Pm for bug-guix@gnu.org; Sat, 30 Mar 2019 02:16:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hA7Hh-0004CZ-NA for bug-guix@gnu.org; Sat, 30 Mar 2019 02:16:07 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:50876) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hA7Hf-0004Bl-0b for bug-guix@gnu.org; Sat, 30 Mar 2019 02:16:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hA7He-0005ct-IU for bug-guix@gnu.org; Sat, 30 Mar 2019 02:16:02 -0400 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <20190329102005.3623fd57@alma-ubu> ("=?UTF-8?Q?Bj=C3=B6rn_?= =?UTF-8?Q?H=C3=B6fling?="'s message of "Fri, 29 Mar 2019 10:20:05 +0100") 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: =?UTF-8?Q?Bj=C3=B6rn_?= =?UTF-8?Q?H=C3=B6fling?= Cc: Alberto EFG , 35012@debbugs.gnu.org Hi Bj=C3=B6rn, Bj=C3=B6rn H=C3=B6fling writes: > On Thu, 28 Mar 2019 23:11:22 -0600 > Alberto EFG wrote: > >> H, Mark and everyone who has been helpful=20 >>=20 >> > As other people have mentioned, this substitute should now be >> > available,=20=20 >> I keep getting this, I don't know if I am doing something wrong: >>=20 >> $ guix package -n -u . >> --substitute-urls=3D"https://mirror.hydra.gnu.org >> https://ci.guix.info" [...] substitute: updating substitutes from >> 'https://mirror.hydra.gnu.org'... 100.0% substitute: updating >> substitutes from 'https://ci.guix.info'... 100.0% The following >> derivations would be >> built: /gnu/store/5xs5i2pkf369g2hd26f2sy26r40bzjm6-icecat-60.6.1-guix1.d= rv /gnu/store/4f40wrx514rbly302ha0gvpn5b53d91f-rust-1.24.1.drv >> /gnu/store/yf5fcqp3v4jf038g454h2zqm54x6ijj6-profile.drv >> 938.6 MB would be downloaded: > > I see that your hash of icecat differs from mine: > > $ guix package -n -i icecat > --substitute-urls=3D"https://mirror.hydra.gnu.org https://ci.guix.info" > The following package would be upgraded: icecat 60.6.1-guix1 =E2=86=92 > 60.6.1-guix1 /gnu/store/bwhnxvfx4ng5fhc7xi6wijp8qciqjpbk-icecat-60.6.1-gu= ix1 The hashes don't match because one is a store derivation (.drv) file and the other is the output store item produced by that derivation. These store items are assigned different hashes. You might expect that the hash of a derivation could be reused for the outputs of that derivation, but it can't be done for a technical reason: the hash in the file name of a store derivation is based on the entire contents of that .drv file. That .drv file also contains its output file names. See the problem? In order to give these the same hash, you would need to create a derivation file that contains its own hash, i.e. the result of hashing its entire contents. That would involve solving an equation of the form: H =3D sha256(X ++ H ++ Y), which is presumably hard :) Regards, Mark