From debbugs-submit-bounces@debbugs.gnu.org Sat Oct 24 00:55:31 2020 Received: (at 43818-done) by debbugs.gnu.org; 24 Oct 2020 04:55:32 +0000 Received: from localhost ([127.0.0.1]:58859 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kWBaV-0002su-Jo for submit@debbugs.gnu.org; Sat, 24 Oct 2020 00:55:31 -0400 Received: from mail-il1-f194.google.com ([209.85.166.194]:44664) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kWBaS-0002sg-RK for 43818-done@debbugs.gnu.org; Sat, 24 Oct 2020 00:55:29 -0400 Received: by mail-il1-f194.google.com with SMTP id z2so3369500ilh.11 for <43818-done@debbugs.gnu.org>; Fri, 23 Oct 2020 21:55:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=rnZ/BcaBf4HxrOM1QPzFYIPbM/7YEE+R1QXUxMkYuck=; b=NwksZ2emTpEpzvh873RxbG3C3n3SzxA0dv1mPYTGSJEKeBTN5BTcmaw9mPjhZyBc2w dDRZ9Sv5iqLPgFdWnFK31Cn+FwJmUkU/3+LJRDwMWNMUiUOPb/t/+T2kENzIU1O0ukGW Snc9vemKcZ5HuH6IQzW9eGUhFo25i+PY71aMQEuZBMYJ3DHmA0prplCyqGThHSx/XB9A ayys9C1dVQnQNrx7ERDGJPzhTYpZPhz72i3Qy+NKZhFsJ0HwPOZbn33cffReH11ddqnP 1vJypkic7JtKi9jSrHWOInbIbf4h9WcWSwKHF6eeA4/hIesQ3GNTSvCT2Yllr7DlPRkn Kf1g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=rnZ/BcaBf4HxrOM1QPzFYIPbM/7YEE+R1QXUxMkYuck=; b=dYEl098K87fG1bLuoLUQGhFFKQ9Y0PAKXsp/CvyrfbouESaAACj5RqxvN6lIYWEPdz /wnMtL2bmZt/uompGeFQfjVf6S9yP5PIpgdw0RKDDOT7mNFmZ0ClZq+qnBYjjPqeCC4L DYLA9pKz77swbcB/Uc+f015oH0xbmXen/qfg5vZU3awHd1goQbIh9Bki645A7HD13uQG XQWHjcs/YkVuvGkNK8E5hpEdaKNEY9qZyYgDuryKyMnDke2KcJ5mhr34ws+jN8ArwGU6 B9SskIwFJ0KrosS2/A5Fg3mnsqTk65gDLq+PTKCxy0nV+k0/+Lat0+z6MyuA9a56pHBi xgZA== X-Gm-Message-State: AOAM5330uJn6KECz4e/OIAQh7tetVLRWCRewW0BxvjjGgIywj27iyTCa +NN03fF6eaBH9fRCzNJ4U5b6Lh4RRvs= X-Google-Smtp-Source: ABdhPJyv7lE+u+aNJcxr+NcywqG1N7rRPL+1VYxTQ+GbMGnosxgVn3TYOOdLM8c71ThyQlVKwTSNMw== X-Received: by 2002:a05:6e02:df4:: with SMTP id m20mr4304716ilj.180.1603515323022; Fri, 23 Oct 2020 21:55:23 -0700 (PDT) Received: from hurd (dsl-159-173.b2b2c.ca. [66.158.159.173]) by smtp.gmail.com with ESMTPSA id m66sm2069914ill.69.2020.10.23.21.55.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 23 Oct 2020 21:55:22 -0700 (PDT) From: Maxim Cournoyer To: 43818-done@debbugs.gnu.org Subject: Re: bug#43818: Use of local-file in icecat-source definition breaks REPL References: <878sckk22g.fsf@gmail.com> Date: Sat, 24 Oct 2020 00:55:16 -0400 In-Reply-To: <878sckk22g.fsf@gmail.com> (Maxim Cournoyer's message of "Mon, 05 Oct 2020 13:36:07 -0400") Message-ID: <87k0vg5ikr.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 43818-done Cc: "Mark H. Weaver" , Christopher Baines X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello, Maxim Cournoyer writes: > CC: Mark H Weaver, one of the Icecat maintainer. > > Hello, > > The problem is that local-file doesn't work in Geiser. This breaks > working at the REPL: > > Enter `,help' for help. > scheme@(guile-user)> ,m (gnu packages linux) > While executing meta-command: > ERROR: > 1. &formatted-message: > format: "~a: patch not found\n" > arguments: ("icecat-use-older-reveal-hidden-html.patch") Thanks for Christopher Baines on #guix who pointed that local-file seemed to behave correctly at the REPL and Geiser (indeed!). It made me try to reproduce it in a --pure environment and I couldn't. After a couple hours digging, I found that this snippet in my modified .dir-locals file: --8<---------------cut here---------------start------------->8--- (with-eval-after-load 'geiser-guile (let ((root-dir (locate-dominating-file default-directory ".dir-locals.el"))) (setq geiser-guile-load-path (cons root-dir (delete root-dir geiser-guile-load-path))))) --8<---------------cut here---------------end--------------->8--- Was the culprit, especially the use of with-eval-after-load (which turned out to be unnecessary). This snippet allows to switch between git worktrees and always have the geiser-guile-load-path (which configures both the Guile %load-path and the %load-compiled-path) set correctly. Here's the diff of my (fixed) .dir-locals in my Guix git checkout: --8<---------------cut here---------------start------------->8--- ~/src/guix$ git diff .dir-locals.el diff --git a/.dir-locals.el b/.dir-locals.el index 19f15b3e1a..0869fbaa20 100644 --- a/.dir-locals.el +++ b/.dir-locals.el @@ -8,7 +8,17 @@ ;; For use with 'bug-reference-prog-mode'. (bug-reference-url-format . "http://bugs.gnu.org/%s") (bug-reference-bug-regexp - . ""))) + . "") + + ;; Emacs-Guix + (eval . (setq guix-directory + (locate-dominating-file default-directory ".dir-locals.el"))) + ;; Geiser + (eval . (let ((root-dir (locate-dominating-file + default-directory ".dir-locals.el"))) + (setq geiser-guile-load-path + (cons root-dir + (delete root-dir geiser-guile-load-path))))))) (c-mode . ((c-file-style . "gnu"))) (scheme-mode . --8<---------------cut here---------------end--------------->8--- I am closing this issue, sorry for the noise! Maxim