From mboxrd@z Thu Jan 1 00:00:00 1970 From: Timothy Sample Subject: bug#37064: Ghc 8.6.5 fails to find core package database Date: Thu, 22 Aug 2019 15:26:37 -0400 Message-ID: <87zhk1f1ci.fsf@ngyro.com> References: <731a105e-4cf8-0d88-798b-3907c458410a@student.ethz.ch> 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]:44039) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i0sjf-0005yh-Sn for bug-guix@gnu.org; Thu, 22 Aug 2019 15:27:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1i0sje-00064J-Nm for bug-guix@gnu.org; Thu, 22 Aug 2019 15:27:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:57759) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1i0sje-00064F-Kb for bug-guix@gnu.org; Thu, 22 Aug 2019 15:27:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1i0sje-0008TY-Ea for bug-guix@gnu.org; Thu, 22 Aug 2019 15:27:02 -0400 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <731a105e-4cf8-0d88-798b-3907c458410a@student.ethz.ch> (Gabriel Giamarchi's message of "Sat, 17 Aug 2019 17:21:08 +0200") 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: Gabriel Giamarchi Cc: 37064@debbugs.gnu.org Hi Gabriel, Gabriel Giamarchi writes: > Installing only 'ghc 8.6.5' (Glasgow Haskell compiler) and sourcing > > '~/.guix-profile/etc/profile' leads to ghc not finding core modules. > ('ghci' doesn't find System.IO for instance). > > This is due to $GHC_PACKAGE_PATH not containing ghc 8.6.5's > package.conf.d, but > instead ghc 8.4.3's database. Ouch! > Note: Not setting this variable leads to a working ghc (will search in > default > location), but is required to install additional packages via guix. > > The issue might come from guix/profiles.scm:812, since > =C2=A0 (module-ref (resolve-interface '(gnu packages haskell)) 'ghc) > evaluates to in my repl. Good catch. I can confirm this is the issue, but I=E2=80=99m not sure how = to fix it. We could try to find GHC from the profile rather than unconditionally using a certain package. However, that would not help if someone were to install GHC 8.4 and 8.6 in the same profile. -- Tim