From unknown Sun Jun 22 17:10:53 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#21127 <21127@debbugs.gnu.org> To: bug#21127 <21127@debbugs.gnu.org> Subject: Status: Problem with guix.el on hybrid systems. Reply-To: bug#21127 <21127@debbugs.gnu.org> Date: Mon, 23 Jun 2025 00:10:53 +0000 retitle 21127 Problem with guix.el on hybrid systems. reassign 21127 guix submitter 21127 Mathieu Lirzin severity 21127 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Fri Jul 24 08:27:50 2015 Received: (at submit) by debbugs.gnu.org; 24 Jul 2015 12:27:50 +0000 Received: from localhost ([127.0.0.1]:57880 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZIc4q-000259-1z for submit@debbugs.gnu.org; Fri, 24 Jul 2015 08:27:50 -0400 Received: from eggs.gnu.org ([208.118.235.92]:57555) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZIc4l-00024z-Gk for submit@debbugs.gnu.org; Fri, 24 Jul 2015 08:27:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZIc4c-0005ZA-Jn for submit@debbugs.gnu.org; Fri, 24 Jul 2015 08:27:43 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:44811) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZIc4c-0005Yy-GX for submit@debbugs.gnu.org; Fri, 24 Jul 2015 08:27:34 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42605) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZIc4X-0001mF-Qf for bug-guix@gnu.org; Fri, 24 Jul 2015 08:27:34 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZIc4L-0005QC-Bk for bug-guix@gnu.org; Fri, 24 Jul 2015 08:27:29 -0400 Received: from smtp28.openmailbox.org ([62.4.1.62]:43022) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZIc4K-0005PL-RC for bug-guix@gnu.org; Fri, 24 Jul 2015 08:27:17 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.openmailbox.org (Postfix) with ESMTP id E2BE12E051E for ; Fri, 24 Jul 2015 14:27:14 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=openmailbox.org; h=content-type:content-type:mime-version:user-agent:message-id :date:date:subject:subject:from:from:received; s=openmailbox; t= 1437740832; bh=BAjn07BSMN0Ozn8VFaCyNVu+Jdkz5a8TXR1Ybc0LM+k=; b=g y6m5qmNGHuy9cYtDyN2AoHqSolHKbmNhlZSdgVvOteUq41BWM2nCHG+jtBPzhkrE wtUzl0ioVRzFQFsz3m0IVe6yQ59+3yW8ZfFLgQc/TIdqTOyFKuvhEjhvvnHqqGns DkqGjRN7t194DIGfrMMbLJLolthZVJY0lbhcxeu6E4= X-Virus-Scanned: amavisd-new at openmailbox.org Received: from mail.openmailbox.org ([62.4.1.34]) by localhost (mail.openmailbox.org [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id j9e9W9CvwpPQ for ; Fri, 24 Jul 2015 14:27:12 +0200 (CEST) From: Mathieu Lirzin To: bug-guix@gnu.org Subject: Problem with guix.el on hybrid systems. Date: Fri, 24 Jul 2015 14:25:13 +0200 Message-ID: <876159eo9i.fsf@openmailbox.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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: -4.0 (----) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hello Guix, A long time ago I've noticed some problems with guix.el when installing Guile from Guix. My setup Guix 0.8.3 built from the tarball and installed ontop of Debian 8 in the /usr/local prefix (nothing fancy :)). At this state everything works fine, guix.el included! First for Guix to be useful I change my paths to choose "$HOME/.guix-profile/...", then I install Guile in my profile, and eventually when I launch the emacs interface, Guix yells at me. --8<---------------cut here---------------start------------->8--- Backtrace: In guix/derivations.scm: 19: 19 [#] In ice-9/boot-9.scm: 2951: 18 [define-module* (guix derivations) #:filename ...] 2926: 17 [resolve-imports (((srfi srfi-1)) ((srfi srfi-9)) ((srfi srfi-9 gn= u)) ...)] 2864: 16 [resolve-interface (guix hash) #:select ...] 2789: 15 [# # ...] 3065: 14 [try-module-autoload (guix hash) #f] 2401: 13 [save-module-excursion #] 3085: 12 [#] In unknown file: ?: 11 [primitive-load-path "guix/hash" ...] In guix/hash.scm: 19: 10 [#] In ice-9/boot-9.scm: 2951: 9 [define-module* (guix hash) #:filename ...] 2926: 8 [resolve-imports ((#) (#) (#) (#) ...)] 2864: 7 [resolve-interface (guix gcrypt) #:select ...] 2789: 6 [# # ...] 3065: 5 [try-module-autoload (guix gcrypt) #f] 2401: 4 [save-module-excursion #] 3085: 3 [#] In unknown file: ?: 2 [primitive-load-path "guix/gcrypt" ...] In guix/gcrypt.scm: 33: 1 [#] In unknown file: ?: 0 [dynamic-link "libgcrypt"] ERROR: In procedure dynamic-link: ERROR: In procedure dynamic-link: file: "libgcrypt", message: "file not fou= nd" --8<---------------cut here---------------end--------------->8--- what is happening is that Guix uses Guile installed from Guix but is unable to dynamically link with the Libgcrypt from debian or even with the Libgcrypt installed from guix in my profile. So my current fix is to add (setq guix-guile-program "/usr/bin/guile") to my .emacs file, then everything works fine. But what should we do to avoid such thing? AIUI we could document it in (info "(guix)Application Setup") or (info "(guix)Emacs Initial Setup"), or even better fix it directly in the code (if possible). Here is my attempt to fix the code with my na=C3=AFve elisp programming. I would be happy to get better suggestion! --=-=-= Content-Type: text/x-diff; charset=utf-8 Content-Disposition: attachment; filename=0001-emacs-Fix-guix-guile-program.patch Content-Transfer-Encoding: quoted-printable >From ca4360cc33f56dbfd1fa1367f68d3bd3d0d7c553 Mon Sep 17 00:00:00 2001 From: Mathieu Lirzin Date: Fri, 24 Jul 2015 12:59:20 +0200 Subject: [PATCH] emacs: Fix guix-guile-program. * emacs/guix-backend.el: Move to ... * emacs/guix-backend.el.in: ... here. (guix-guile-program): Default to the Guile used when building Guix to avoid breaking guix.el when installing another Guile. * configure.ac: Adapt to it. * .gitignore: Likewise. --- .gitignore | 1 + configure.ac | 3 +- emacs/guix-backend.el | 378 -------------------------------------------= --- emacs/guix-backend.el.in | 379 +++++++++++++++++++++++++++++++++++++++++++= ++++ 4 files changed, 382 insertions(+), 379 deletions(-) delete mode 100644 emacs/guix-backend.el create mode 100644 emacs/guix-backend.el.in diff --git a/.gitignore b/.gitignore index c7a6cdd..d3499f7 100644 --- a/.gitignore +++ b/.gitignore @@ -119,6 +119,7 @@ GTAGS /emacs/Makefile.in /emacs/Makefile /emacs/guix-autoloads.el +/emacs/guix-backend.el /emacs/guix-helper.scm /emacs/guix-init.el /emacs/guix-profiles.el diff --git a/configure.ac b/configure.ac index 2c8b9f0..1cbcffc 100644 --- a/configure.ac +++ b/configure.ac @@ -200,7 +200,8 @@ AM_CONDITIONAL([HAVE_EMACS], [test "x$EMACS" !=3D "xno"= ]) =20 emacsuidir=3D"${guilemoduledir}/guix/emacs" AC_SUBST([emacsuidir]) -AC_CONFIG_FILES([emacs/guix-init.el +AC_CONFIG_FILES([emacs/guix-backend.el + emacs/guix-init.el emacs/guix-profiles.el emacs/guix-helper.scm]) =20 diff --git a/emacs/guix-backend.el b/emacs/guix-backend.el deleted file mode 100644 index 73a429b..0000000 --- a/emacs/guix-backend.el +++ /dev/null @@ -1,378 +0,0 @@ -;;; guix-backend.el --- Communication with Geiser - -;; Copyright =C2=A9 2014 Alex Kost - -;; This file is part of GNU Guix. - -;; GNU Guix is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation, either version 3 of the License, or -;; (at your option) any later version. - -;; GNU Guix is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with this program. If not, see . - -;;; Commentary: - -;; This file provides the code for interacting with Guile using Geiser. - -;; By default (if `guix-use-guile-server' is non-nil) 2 Geiser REPLs are -;; started. The main one (with "guile --listen" process) is used for -;; "interacting" with a user - for showing a progress of -;; installing/deleting Guix packages. The second (internal) REPL is -;; used for synchronous evaluating, e.g. when information about -;; packages/generations should be received for a list/info buffer. -;; -;; This "2 REPLs concept" makes it possible to have a running process of -;; installing/deleting packages and to continue to search/list/get info -;; about other packages at the same time. If you prefer to use a single -;; Guix REPL, do not try to receive any information while there is a -;; running code in the REPL (see -;; ). -;; -;; If you need to use "guix.el" in another Emacs (i.e. when there is -;; a runnig "guile --listen..." REPL somewhere), you can either change -;; `guix-default-port' in that Emacs instance or set -;; `guix-use-guile-server' to t. -;; -;; Guix REPLs (unlike the usual Geiser REPLs) are not added to -;; `geiser-repl--repls' variable, and thus cannot be used for evaluating -;; while editing scm-files. The only purpose of Guix REPLs is to be an -;; intermediate between "Guix/Guile level" and "Emacs interface level". -;; That being said you can still want to use a Guix REPL while hacking -;; auxiliary scheme-files for "guix.el". You can just use "M-x -;; connect-to-guile" (connect to "localhost" and `guix-default-port') to -;; have a usual Geiser REPL with all stuff defined by "guix.el" package. - -;;; Code: - -(require 'geiser-mode) -(require 'guix-emacs) - -(defvar guix-load-path - (file-name-directory (or load-file-name - (locate-library "guix"))) - "Directory with scheme files for \"guix.el\" package.") - -(defvar guix-helper-file - (expand-file-name "guix-helper.scm" guix-load-path) - "Auxiliary scheme file for loading.") - -(defvar guix-guile-program (or geiser-guile-binary "guile") - "Name of the guile executable used for Guix REPL. -May be either a string (the name of the executable) or a list of -strings of the form: - - (NAME . ARGS) - -Where ARGS is a list of arguments to the guile program.") - - -;;; REPL - -(defgroup guix-repl nil - "Settings for Guix REPLs." - :prefix "guix-repl-" - :group 'guix) - -(defcustom guix-repl-startup-time 30000 - "Time, in milliseconds, to wait for Guix REPL to startup. -Same as `geiser-repl-startup-time' but is used for Guix REPL. -If you have a slow system, try to increase this time." - :type 'integer - :group 'guix-repl) - -(defcustom guix-repl-buffer-name "*Guix REPL*" - "Default name of a Geiser REPL buffer used for Guix." - :type 'string - :group 'guix-repl) - -(defcustom guix-after-start-repl-hook () - "Hook called after Guix REPL is started." - :type 'hook - :group 'guix-repl) - -(defcustom guix-use-guile-server t - "If non-nil, start guile with '--listen' argument. -This allows to receive information about packages using an additional -REPL while some packages are being installed/removed in the main REPL." - :type 'boolean - :group 'guix-repl) - -(defcustom guix-default-port 37246 - "Default port used if `guix-use-guile-server' is non-nil." - :type 'integer - :group 'guix-repl) - -(defvar guix-repl-buffer nil - "Main Geiser REPL buffer used for communicating with Guix. -This REPL is used for processing package actions and for -receiving information if `guix-use-guile-server' is nil.") - -(defvar guix-internal-repl-buffer nil - "Additional Geiser REPL buffer used for communicating with Guix. -This REPL is used for receiving information only if -`guix-use-guile-server' is non-nil.") - -(defvar guix-internal-repl-buffer-name "*Guix Internal REPL*" - "Default name of an internal Guix REPL buffer.") - -(defvar guix-before-repl-operation-hook nil - "Hook run before executing an operation in Guix REPL.") - -(defvar guix-after-repl-operation-hook - '(guix-emacs-load-autoloads-maybe - guix-repl-operation-success-message) - "Hook run after executing successful operation in Guix REPL.") - -(defvar guix-repl-operation-p nil - "Non-nil, if current operation is performed by `guix-eval-in-repl'. -This internal variable is used to distinguish Guix operations -from operations performed in Guix REPL by a user.") - -(defvar guix-repl-operation-type nil - "Type of the current operation performed by `guix-eval-in-repl'. -This internal variable is used to define what actions should be -executed after the current operation succeeds. -See `guix-eval-in-repl' for details.") - -(defun guix-repl-operation-success-message () - "Message telling about successful Guix operation." - (message "Guix operation has been performed.")) - -(defun guix-get-guile-program (&optional internal) - "Return a value suitable for `geiser-guile-binary'." - (if (or internal - (not guix-use-guile-server)) - guix-guile-program - (append (if (listp guix-guile-program) - guix-guile-program - (list guix-guile-program)) - ;; Guile understands "--listen=3D..." but not "--listen ..." - (list (concat "--listen=3D" - (number-to-string guix-default-port)))))) - -(defun guix-start-process-maybe (&optional start-msg end-msg) - "Start Geiser REPL configured for Guix if needed. -START-MSG and END-MSG are strings displayed in the minibuffer in -the beginning and in the end of the starting process. If nil, -display default messages." - (guix-start-repl-maybe nil - (or start-msg "Starting Guix REPL ...") - (or end-msg "Guix REPL has been started.")) - (if guix-use-guile-server - (guix-start-repl-maybe 'internal) - (setq guix-internal-repl-buffer guix-repl-buffer))) - -(defun guix-start-repl-maybe (&optional internal start-msg end-msg) - "Start Guix REPL if needed. -If INTERNAL is non-nil, start an internal REPL. - -START-MSG and END-MSG are strings displayed in the minibuffer in -the beginning and in the end of the process. If nil, do not -display messages." - (let* ((repl-var (guix-get-repl-buffer-variable internal)) - (repl (symbol-value repl-var))) - (unless (and (buffer-live-p repl) - (get-buffer-process repl)) - (and start-msg (message start-msg)) - (setq guix-repl-operation-p nil) - (let ((geiser-guile-binary (guix-get-guile-program internal)) - (geiser-guile-init-file (or internal guix-helper-file)) - (repl (get-buffer-create - (guix-get-repl-buffer-name internal)))) - (condition-case err - (guix-start-repl repl - (and internal - (geiser-repl--read-address - "localhost" guix-default-port))) - (text-read-only - (error (concat "Couldn't start Guix REPL. Perhaps the port %s = is busy.\n" - "See buffer '%s' for details") - guix-default-port (buffer-name repl)))) - (set repl-var repl) - (and end-msg (message end-msg)) - (unless internal - (run-hooks 'guix-after-start-repl-hook)))))) - -(defun guix-start-repl (buffer &optional address) - "Start Guix REPL in BUFFER. -If ADDRESS is non-nil, connect to a remote guile process using -this address (it should be defined by -`geiser-repl--read-address')." - ;; A mix of the code from `geiser-repl--start-repl' and - ;; `geiser-repl--to-repl-buffer'. - (let ((impl 'guile) - (geiser-guile-load-path (cons guix-load-path - geiser-guile-load-path)) - (geiser-repl-startup-time guix-repl-startup-time)) - (with-current-buffer buffer - (geiser-repl-mode) - (geiser-impl--set-buffer-implementation impl) - (geiser-repl--autodoc-mode -1) - (goto-char (point-max)) - (let ((prompt (geiser-con--combined-prompt - geiser-guile--prompt-regexp - geiser-guile--debugger-prompt-regexp))) - (geiser-repl--save-remote-data address) - (geiser-repl--start-scheme impl address prompt) - (geiser-repl--quit-setup) - (geiser-repl--history-setup) - (setq-local geiser-repl--repls (list buffer)) - (geiser-repl--set-this-buffer-repl buffer) - (setq geiser-repl--connection - (geiser-con--make-connection - (get-buffer-process (current-buffer)) - geiser-guile--prompt-regexp - geiser-guile--debugger-prompt-regexp)) - (geiser-repl--startup impl address) - (geiser-repl--autodoc-mode 1) - (geiser-company--setup geiser-repl-company-p) - (add-hook 'comint-output-filter-functions - 'guix-repl-output-filter - nil t) - (set-process-query-on-exit-flag - (get-buffer-process (current-buffer)) - geiser-repl-query-on-kill-p))))) - -(defun guix-repl-output-filter (str) - "Filter function suitable for `comint-output-filter-functions'. -This is a replacement for `geiser-repl--output-filter'." - (cond - ((string-match-p geiser-guile--prompt-regexp str) - (geiser-autodoc--disinhibit-autodoc) - (when guix-repl-operation-p - (setq guix-repl-operation-p nil) - (run-hooks 'guix-after-repl-operation-hook) - ;; Run hooks specific to the current operation type. - (when guix-repl-operation-type - (let ((type-hook (intern - (concat "guix-after-" - (symbol-name guix-repl-operation-type) - "-hook")))) - (setq guix-repl-operation-type nil) - (and (boundp type-hook) - (run-hooks type-hook)))))) - ((string-match geiser-guile--debugger-prompt-regexp str) - (setq guix-repl-operation-p nil) - (geiser-con--connection-set-debugging geiser-repl--connection - (match-beginning 0)) - (geiser-autodoc--disinhibit-autodoc)))) - -(defun guix-repl-exit (&optional internal no-wait) - "Exit the current Guix REPL. -If INTERNAL is non-nil, exit the internal REPL. -If NO-WAIT is non-nil, do not wait for the REPL process to exit: -send a kill signal to it and return immediately." - (let ((repl (symbol-value (guix-get-repl-buffer-variable internal)))) - (when (get-buffer-process repl) - (with-current-buffer repl - (geiser-con--connection-deactivate geiser-repl--connection t) - (comint-kill-subjob) - (unless no-wait - (while (get-buffer-process repl) - (sleep-for 0.1))))))) - -(defun guix-get-repl-buffer (&optional internal) - "Return Guix REPL buffer; start REPL if needed. -If INTERNAL is non-nil, return an additional internal REPL." - (guix-start-process-maybe) - (let ((repl (symbol-value (guix-get-repl-buffer-variable internal)))) - ;; If a new Geiser REPL is started, `geiser-repl--repl' variable may - ;; be set to the new value in a Guix REPL, so set it back to a - ;; proper value here. - (with-current-buffer repl - (geiser-repl--set-this-buffer-repl repl)) - repl)) - -(defun guix-get-repl-buffer-variable (&optional internal) - "Return the name of a variable with a REPL buffer." - (if internal - 'guix-internal-repl-buffer - 'guix-repl-buffer)) - -(defun guix-get-repl-buffer-name (&optional internal) - "Return the name of a REPL buffer." - (if internal - guix-internal-repl-buffer-name - guix-repl-buffer-name)) - -(defun guix-switch-to-repl (&optional internal) - "Switch to Guix REPL. -If INTERNAL is non-nil (interactively with prefix), switch to the -additional internal REPL if it exists." - (interactive "P") - (geiser-repl--switch-to-buffer (guix-get-repl-buffer internal))) - - -;;; Evaluating expressions - -(defvar guix-operation-buffer nil - "Buffer from which the latest Guix operation was performed.") - -(defun guix-make-guile-expression (fun &rest args) - "Return string containing a guile expression for calling FUN with ARGS." - (format "(%S %s)" fun - (mapconcat - (lambda (arg) - (cond - ((null arg) "'()") - ((or (eq arg t) - ;; An ugly hack to separate 'false' from nil - (equal arg 'f) - (keywordp arg)) - (concat "#" (prin1-to-string arg t))) - ((or (symbolp arg) (listp arg)) - (concat "'" (prin1-to-string arg))) - (t (prin1-to-string arg)))) - args - " "))) - -(defun guix-eval (str &optional wrap) - "Evaluate guile expression STR. -If WRAP is non-nil, wrap STR into (begin ...) form. -Return a list of strings with result values of evaluation." - (with-current-buffer (guix-get-repl-buffer 'internal) - (let* ((wrapped (if wrap (geiser-debug--wrap-region str) str)) - (code `(:eval (:scm ,wrapped))) - (ret (geiser-eval--send/wait code))) - (if (geiser-eval--retort-error ret) - (error "Error in evaluating guile expression: %s" - (geiser-eval--retort-output ret)) - (cdr (assq 'result ret)))))) - -(defun guix-eval-read (str &optional wrap) - "Evaluate guile expression STR. -For the meaning of WRAP, see `guix-eval'. -Return elisp expression of the first result value of evaluation." - ;; Parsing scheme code with elisp `read' is probably not the best idea. - (read (replace-regexp-in-string - "#f\\|#" "nil" - (replace-regexp-in-string - "#t" "t" (car (guix-eval str wrap)))))) - -(defun guix-eval-in-repl (str &optional operation-buffer operation-type) - "Switch to Guix REPL and evaluate STR with guile expression there. -If OPERATION-BUFFER is non-nil, it should be a buffer from which -the current operation was performed. - -If OPERATION-TYPE is non-nil, it should be a symbol. After -successful executing of the current operation, -`guix-after-OPERATION-TYPE-hook' is called." - (run-hooks 'guix-before-repl-operation-hook) - (setq guix-repl-operation-p t - guix-repl-operation-type operation-type - guix-operation-buffer operation-buffer) - (let ((repl (guix-get-repl-buffer))) - (with-current-buffer repl - (geiser-repl--send str)) - (geiser-repl--switch-to-buffer repl))) - -(provide 'guix-backend) - -;;; guix-backend.el ends here diff --git a/emacs/guix-backend.el.in b/emacs/guix-backend.el.in new file mode 100644 index 0000000..c283131 --- /dev/null +++ b/emacs/guix-backend.el.in @@ -0,0 +1,379 @@ +;;; guix-backend.el --- Communication with Geiser + +;; Copyright =C2=A9 2014 Alex Kost +;; Copyright =C2=A9 2015 Mathieu Lirzin + +;; This file is part of GNU Guix. + +;; GNU Guix is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation, either version 3 of the License, or +;; (at your option) any later version. + +;; GNU Guix is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with this program. If not, see . + +;;; Commentary: + +;; This file provides the code for interacting with Guile using Geiser. + +;; By default (if `guix-use-guile-server' is non-nil) 2 Geiser REPLs are +;; started. The main one (with "guile --listen" process) is used for +;; "interacting" with a user - for showing a progress of +;; installing/deleting Guix packages. The second (internal) REPL is +;; used for synchronous evaluating, e.g. when information about +;; packages/generations should be received for a list/info buffer. +;; +;; This "2 REPLs concept" makes it possible to have a running process of +;; installing/deleting packages and to continue to search/list/get info +;; about other packages at the same time. If you prefer to use a single +;; Guix REPL, do not try to receive any information while there is a +;; running code in the REPL (see +;; ). +;; +;; If you need to use "guix.el" in another Emacs (i.e. when there is +;; a runnig "guile --listen..." REPL somewhere), you can either change +;; `guix-default-port' in that Emacs instance or set +;; `guix-use-guile-server' to t. +;; +;; Guix REPLs (unlike the usual Geiser REPLs) are not added to +;; `geiser-repl--repls' variable, and thus cannot be used for evaluating +;; while editing scm-files. The only purpose of Guix REPLs is to be an +;; intermediate between "Guix/Guile level" and "Emacs interface level". +;; That being said you can still want to use a Guix REPL while hacking +;; auxiliary scheme-files for "guix.el". You can just use "M-x +;; connect-to-guile" (connect to "localhost" and `guix-default-port') to +;; have a usual Geiser REPL with all stuff defined by "guix.el" package. + +;;; Code: + +(require 'geiser-mode) +(require 'guix-emacs) + +(defvar guix-load-path + (file-name-directory (or load-file-name + (locate-library "guix"))) + "Directory with scheme files for \"guix.el\" package.") + +(defvar guix-helper-file + (expand-file-name "guix-helper.scm" guix-load-path) + "Auxiliary scheme file for loading.") + +(defvar guix-guile-program "@GUILE@" + "Name of the guile executable used for Guix REPL. +May be either a string (the name of the executable) or a list of +strings of the form: + + (NAME . ARGS) + +Where ARGS is a list of arguments to the guile program.") + + +;;; REPL + +(defgroup guix-repl nil + "Settings for Guix REPLs." + :prefix "guix-repl-" + :group 'guix) + +(defcustom guix-repl-startup-time 30000 + "Time, in milliseconds, to wait for Guix REPL to startup. +Same as `geiser-repl-startup-time' but is used for Guix REPL. +If you have a slow system, try to increase this time." + :type 'integer + :group 'guix-repl) + +(defcustom guix-repl-buffer-name "*Guix REPL*" + "Default name of a Geiser REPL buffer used for Guix." + :type 'string + :group 'guix-repl) + +(defcustom guix-after-start-repl-hook () + "Hook called after Guix REPL is started." + :type 'hook + :group 'guix-repl) + +(defcustom guix-use-guile-server t + "If non-nil, start guile with '--listen' argument. +This allows to receive information about packages using an additional +REPL while some packages are being installed/removed in the main REPL." + :type 'boolean + :group 'guix-repl) + +(defcustom guix-default-port 37246 + "Default port used if `guix-use-guile-server' is non-nil." + :type 'integer + :group 'guix-repl) + +(defvar guix-repl-buffer nil + "Main Geiser REPL buffer used for communicating with Guix. +This REPL is used for processing package actions and for +receiving information if `guix-use-guile-server' is nil.") + +(defvar guix-internal-repl-buffer nil + "Additional Geiser REPL buffer used for communicating with Guix. +This REPL is used for receiving information only if +`guix-use-guile-server' is non-nil.") + +(defvar guix-internal-repl-buffer-name "*Guix Internal REPL*" + "Default name of an internal Guix REPL buffer.") + +(defvar guix-before-repl-operation-hook nil + "Hook run before executing an operation in Guix REPL.") + +(defvar guix-after-repl-operation-hook + '(guix-emacs-load-autoloads-maybe + guix-repl-operation-success-message) + "Hook run after executing successful operation in Guix REPL.") + +(defvar guix-repl-operation-p nil + "Non-nil, if current operation is performed by `guix-eval-in-repl'. +This internal variable is used to distinguish Guix operations +from operations performed in Guix REPL by a user.") + +(defvar guix-repl-operation-type nil + "Type of the current operation performed by `guix-eval-in-repl'. +This internal variable is used to define what actions should be +executed after the current operation succeeds. +See `guix-eval-in-repl' for details.") + +(defun guix-repl-operation-success-message () + "Message telling about successful Guix operation." + (message "Guix operation has been performed.")) + +(defun guix-get-guile-program (&optional internal) + "Return a value suitable for `geiser-guile-binary'." + (if (or internal + (not guix-use-guile-server)) + guix-guile-program + (append (if (listp guix-guile-program) + guix-guile-program + (list guix-guile-program)) + ;; Guile understands "--listen=3D..." but not "--listen ..." + (list (concat "--listen=3D" + (number-to-string guix-default-port)))))) + +(defun guix-start-process-maybe (&optional start-msg end-msg) + "Start Geiser REPL configured for Guix if needed. +START-MSG and END-MSG are strings displayed in the minibuffer in +the beginning and in the end of the starting process. If nil, +display default messages." + (guix-start-repl-maybe nil + (or start-msg "Starting Guix REPL ...") + (or end-msg "Guix REPL has been started.")) + (if guix-use-guile-server + (guix-start-repl-maybe 'internal) + (setq guix-internal-repl-buffer guix-repl-buffer))) + +(defun guix-start-repl-maybe (&optional internal start-msg end-msg) + "Start Guix REPL if needed. +If INTERNAL is non-nil, start an internal REPL. + +START-MSG and END-MSG are strings displayed in the minibuffer in +the beginning and in the end of the process. If nil, do not +display messages." + (let* ((repl-var (guix-get-repl-buffer-variable internal)) + (repl (symbol-value repl-var))) + (unless (and (buffer-live-p repl) + (get-buffer-process repl)) + (and start-msg (message start-msg)) + (setq guix-repl-operation-p nil) + (let ((geiser-guile-binary (guix-get-guile-program internal)) + (geiser-guile-init-file (or internal guix-helper-file)) + (repl (get-buffer-create + (guix-get-repl-buffer-name internal)))) + (condition-case err + (guix-start-repl repl + (and internal + (geiser-repl--read-address + "localhost" guix-default-port))) + (text-read-only + (error (concat "Couldn't start Guix REPL. Perhaps the port %s = is busy.\n" + "See buffer '%s' for details") + guix-default-port (buffer-name repl)))) + (set repl-var repl) + (and end-msg (message end-msg)) + (unless internal + (run-hooks 'guix-after-start-repl-hook)))))) + +(defun guix-start-repl (buffer &optional address) + "Start Guix REPL in BUFFER. +If ADDRESS is non-nil, connect to a remote guile process using +this address (it should be defined by +`geiser-repl--read-address')." + ;; A mix of the code from `geiser-repl--start-repl' and + ;; `geiser-repl--to-repl-buffer'. + (let ((impl 'guile) + (geiser-guile-load-path (cons guix-load-path + geiser-guile-load-path)) + (geiser-repl-startup-time guix-repl-startup-time)) + (with-current-buffer buffer + (geiser-repl-mode) + (geiser-impl--set-buffer-implementation impl) + (geiser-repl--autodoc-mode -1) + (goto-char (point-max)) + (let ((prompt (geiser-con--combined-prompt + geiser-guile--prompt-regexp + geiser-guile--debugger-prompt-regexp))) + (geiser-repl--save-remote-data address) + (geiser-repl--start-scheme impl address prompt) + (geiser-repl--quit-setup) + (geiser-repl--history-setup) + (setq-local geiser-repl--repls (list buffer)) + (geiser-repl--set-this-buffer-repl buffer) + (setq geiser-repl--connection + (geiser-con--make-connection + (get-buffer-process (current-buffer)) + geiser-guile--prompt-regexp + geiser-guile--debugger-prompt-regexp)) + (geiser-repl--startup impl address) + (geiser-repl--autodoc-mode 1) + (geiser-company--setup geiser-repl-company-p) + (add-hook 'comint-output-filter-functions + 'guix-repl-output-filter + nil t) + (set-process-query-on-exit-flag + (get-buffer-process (current-buffer)) + geiser-repl-query-on-kill-p))))) + +(defun guix-repl-output-filter (str) + "Filter function suitable for `comint-output-filter-functions'. +This is a replacement for `geiser-repl--output-filter'." + (cond + ((string-match-p geiser-guile--prompt-regexp str) + (geiser-autodoc--disinhibit-autodoc) + (when guix-repl-operation-p + (setq guix-repl-operation-p nil) + (run-hooks 'guix-after-repl-operation-hook) + ;; Run hooks specific to the current operation type. + (when guix-repl-operation-type + (let ((type-hook (intern + (concat "guix-after-" + (symbol-name guix-repl-operation-type) + "-hook")))) + (setq guix-repl-operation-type nil) + (and (boundp type-hook) + (run-hooks type-hook)))))) + ((string-match geiser-guile--debugger-prompt-regexp str) + (setq guix-repl-operation-p nil) + (geiser-con--connection-set-debugging geiser-repl--connection + (match-beginning 0)) + (geiser-autodoc--disinhibit-autodoc)))) + +(defun guix-repl-exit (&optional internal no-wait) + "Exit the current Guix REPL. +If INTERNAL is non-nil, exit the internal REPL. +If NO-WAIT is non-nil, do not wait for the REPL process to exit: +send a kill signal to it and return immediately." + (let ((repl (symbol-value (guix-get-repl-buffer-variable internal)))) + (when (get-buffer-process repl) + (with-current-buffer repl + (geiser-con--connection-deactivate geiser-repl--connection t) + (comint-kill-subjob) + (unless no-wait + (while (get-buffer-process repl) + (sleep-for 0.1))))))) + +(defun guix-get-repl-buffer (&optional internal) + "Return Guix REPL buffer; start REPL if needed. +If INTERNAL is non-nil, return an additional internal REPL." + (guix-start-process-maybe) + (let ((repl (symbol-value (guix-get-repl-buffer-variable internal)))) + ;; If a new Geiser REPL is started, `geiser-repl--repl' variable may + ;; be set to the new value in a Guix REPL, so set it back to a + ;; proper value here. + (with-current-buffer repl + (geiser-repl--set-this-buffer-repl repl)) + repl)) + +(defun guix-get-repl-buffer-variable (&optional internal) + "Return the name of a variable with a REPL buffer." + (if internal + 'guix-internal-repl-buffer + 'guix-repl-buffer)) + +(defun guix-get-repl-buffer-name (&optional internal) + "Return the name of a REPL buffer." + (if internal + guix-internal-repl-buffer-name + guix-repl-buffer-name)) + +(defun guix-switch-to-repl (&optional internal) + "Switch to Guix REPL. +If INTERNAL is non-nil (interactively with prefix), switch to the +additional internal REPL if it exists." + (interactive "P") + (geiser-repl--switch-to-buffer (guix-get-repl-buffer internal))) + + +;;; Evaluating expressions + +(defvar guix-operation-buffer nil + "Buffer from which the latest Guix operation was performed.") + +(defun guix-make-guile-expression (fun &rest args) + "Return string containing a guile expression for calling FUN with ARGS." + (format "(%S %s)" fun + (mapconcat + (lambda (arg) + (cond + ((null arg) "'()") + ((or (eq arg t) + ;; An ugly hack to separate 'false' from nil + (equal arg 'f) + (keywordp arg)) + (concat "#" (prin1-to-string arg t))) + ((or (symbolp arg) (listp arg)) + (concat "'" (prin1-to-string arg))) + (t (prin1-to-string arg)))) + args + " "))) + +(defun guix-eval (str &optional wrap) + "Evaluate guile expression STR. +If WRAP is non-nil, wrap STR into (begin ...) form. +Return a list of strings with result values of evaluation." + (with-current-buffer (guix-get-repl-buffer 'internal) + (let* ((wrapped (if wrap (geiser-debug--wrap-region str) str)) + (code `(:eval (:scm ,wrapped))) + (ret (geiser-eval--send/wait code))) + (if (geiser-eval--retort-error ret) + (error "Error in evaluating guile expression: %s" + (geiser-eval--retort-output ret)) + (cdr (assq 'result ret)))))) + +(defun guix-eval-read (str &optional wrap) + "Evaluate guile expression STR. +For the meaning of WRAP, see `guix-eval'. +Return elisp expression of the first result value of evaluation." + ;; Parsing scheme code with elisp `read' is probably not the best idea. + (read (replace-regexp-in-string + "#f\\|#" "nil" + (replace-regexp-in-string + "#t" "t" (car (guix-eval str wrap)))))) + +(defun guix-eval-in-repl (str &optional operation-buffer operation-type) + "Switch to Guix REPL and evaluate STR with guile expression there. +If OPERATION-BUFFER is non-nil, it should be a buffer from which +the current operation was performed. + +If OPERATION-TYPE is non-nil, it should be a symbol. After +successful executing of the current operation, +`guix-after-OPERATION-TYPE-hook' is called." + (run-hooks 'guix-before-repl-operation-hook) + (setq guix-repl-operation-p t + guix-repl-operation-type operation-type + guix-operation-buffer operation-buffer) + (let ((repl (guix-get-repl-buffer))) + (with-current-buffer repl + (geiser-repl--send str)) + (geiser-repl--switch-to-buffer repl))) + +(provide 'guix-backend) + +;;; guix-backend.el ends here --=20 2.4.3 --=-=-= Content-Type: text/plain -- Mathieu Lirzin --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Fri Jul 24 16:31:30 2015 Received: (at 21127) by debbugs.gnu.org; 24 Jul 2015 20:31:30 +0000 Received: from localhost ([127.0.0.1]:58230 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZIjcw-0006rZ-40 for submit@debbugs.gnu.org; Fri, 24 Jul 2015 16:31:30 -0400 Received: from eggs.gnu.org ([208.118.235.92]:52119) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZIjct-0006rR-9r for 21127@debbugs.gnu.org; Fri, 24 Jul 2015 16:31:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZIjcs-0006Vn-8v for 21127@debbugs.gnu.org; Fri, 24 Jul 2015 16:31:26 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-3.1 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:52407) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZIjco-0006UB-1b; Fri, 24 Jul 2015 16:31:22 -0400 Received: from reverse-83.fdn.fr ([80.67.176.83]:56801 helo=pluto) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1ZIjcn-0003U9-E4; Fri, 24 Jul 2015 16:31:21 -0400 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) To: Mathieu Lirzin Subject: Re: bug#21127: Problem with guix.el on hybrid systems. References: <876159eo9i.fsf@openmailbox.org> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 6 Thermidor an 223 de la =?utf-8?Q?R=C3=A9volution?= X-PGP-Key-ID: 0x3D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-unknown-linux-gnu Date: Fri, 24 Jul 2015 22:31:19 +0200 In-Reply-To: <876159eo9i.fsf@openmailbox.org> (Mathieu Lirzin's message of "Fri, 24 Jul 2015 14:25:13 +0200") Message-ID: <87h9otfgbs.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::e X-Spam-Score: -6.2 (------) X-Debbugs-Envelope-To: 21127 Cc: 21127@debbugs.gnu.org, Alex Kost X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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: -6.2 (------) Mathieu Lirzin skribis: > From ca4360cc33f56dbfd1fa1367f68d3bd3d0d7c553 Mon Sep 17 00:00:00 2001 > From: Mathieu Lirzin > Date: Fri, 24 Jul 2015 12:59:20 +0200 > Subject: [PATCH] emacs: Fix guix-guile-program. > > * emacs/guix-backend.el: Move to ... > * emacs/guix-backend.el.in: ... here. > (guix-guile-program): Default to the Guile used when building Guix to > avoid breaking guix.el when installing another Guile. > * configure.ac: Adapt to it. > * .gitignore: Likewise. [...] > +(defvar guix-guile-program "@GUILE@" Sounds reasonable to me. Alternately, I wonder if it would make sense to define that variable in guix-init.el to avoid having an additional .in file. Alex, WDYT? Thanks, Ludo'. From debbugs-submit-bounces@debbugs.gnu.org Sat Jul 25 03:52:22 2015 Received: (at 21127) by debbugs.gnu.org; 25 Jul 2015 07:52:22 +0000 Received: from localhost ([127.0.0.1]:58324 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZIuFq-0006PH-9v for submit@debbugs.gnu.org; Sat, 25 Jul 2015 03:52:22 -0400 Received: from mail-la0-f43.google.com ([209.85.215.43]:36600) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZIuFm-0006P7-Nl for 21127@debbugs.gnu.org; Sat, 25 Jul 2015 03:52:19 -0400 Received: by lagw2 with SMTP id w2so25237664lag.3 for <21127@debbugs.gnu.org>; Sat, 25 Jul 2015 00:52:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type:content-transfer-encoding; bh=XH6WHGD+dnt9/r+nLN3FAoYLjN2Ka54DII3g1JWYk0M=; b=MN5PYAtjF0sKiRyG/mlza+a5tIXnWCSJD4ydWcbjnPuTNh76z+QBxS7NCBMOzEDq5U 5ob1SFaQDb0WtCemQzjYRNs5VwTknHHIy9SiHeEPZkOnrkvkIB3pGsvecc19fDbSVVN5 RHtqqtG+cuduYQa2ZwSRja/ZqLzP1PeH0TLtRx29eucWFLaiTxvt+dStPKOoXuelYwyI T4mJQyIptkjL4kD4F6GngVG/Nf/VRpK8+81PJjY1wtmVDaxAhki2u1mb4r3DR0xrCgCb kWdrW+tVALrsq3ebtnGoF7yYqHVOMCv0HUx4EKG9AQSkG1funfGGbSY03v4DAvEmBSLh ferA== X-Received: by 10.112.24.233 with SMTP id x9mr17830072lbf.7.1437810737668; Sat, 25 Jul 2015 00:52:17 -0700 (PDT) Received: from leviafan ([217.107.192.146]) by smtp.gmail.com with ESMTPSA id un4sm2399642lbb.7.2015.07.25.00.52.15 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 25 Jul 2015 00:52:16 -0700 (PDT) From: Alex Kost To: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: bug#21127: Problem with guix.el on hybrid systems. References: <876159eo9i.fsf@openmailbox.org> <87h9otfgbs.fsf@gnu.org> Date: Sat, 25 Jul 2015 10:52:17 +0300 In-Reply-To: <87h9otfgbs.fsf@gnu.org> ("Ludovic \=\?utf-8\?Q\?Court\=C3\=A8s\=22'\?\= \=\?utf-8\?Q\?s\?\= message of "Fri, 24 Jul 2015 22:31:19 +0200") Message-ID: <87fv4c3c9a.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 21127 Cc: 21127@debbugs.gnu.org, Mathieu Lirzin X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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: -0.7 (/) Ludovic Court=C3=A8s (2015-07-24 23:31 +0300) wrote: > Mathieu Lirzin skribis: > >> From ca4360cc33f56dbfd1fa1367f68d3bd3d0d7c553 Mon Sep 17 00:00:00 2001 >> From: Mathieu Lirzin >> Date: Fri, 24 Jul 2015 12:59:20 +0200 >> Subject: [PATCH] emacs: Fix guix-guile-program. >> >> * emacs/guix-backend.el: Move to ... >> * emacs/guix-backend.el.in: ... here. >> (guix-guile-program): Default to the Guile used when building Guix to >> avoid breaking guix.el when installing another Guile. >> * configure.ac: Adapt to it. >> * .gitignore: Likewise. > > [...] > >> +(defvar guix-guile-program "@GUILE@" > > Sounds reasonable to me. > > Alternately, I wonder if it would make sense to define that variable in > guix-init.el to avoid having an additional .in file. > > Alex, WDYT? Mathieu, thanks for catching it! I also think that it is better to avoid converting "guix-backend.el" into ".in" file. I had the same question with 'guix-load-path' variable when Emacs UI was merging into Guix: this var was defined in "guix-backend.el" but it had to depend on @prefix@, so I just put another "(defvar =E2=80=A6)" into "guix-init.el.in". As you can see there are 2 definitions of 'guix-load-path': - in "guix-backend.el" (with an old "configure"-independent value) - and in "guix-init.el" (with the current default value). So I suggest to do the same with 'guix-guile-program', i.e. to put (defvar guix-guile-program "@GUILE" =E2=80=A6) into "guix-init.el.in" and that's it. Since "guix-init.el" is loaded the first, "defvar" in "guix-backend.el" will not override the default value. --=20 Alex From debbugs-submit-bounces@debbugs.gnu.org Fri Sep 11 13:26:58 2015 Received: (at 21127-done) by debbugs.gnu.org; 11 Sep 2015 17:26:58 +0000 Received: from localhost ([127.0.0.1]:57241 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZaS6D-0006k5-Ko for submit@debbugs.gnu.org; Fri, 11 Sep 2015 13:26:58 -0400 Received: from eggs.gnu.org ([208.118.235.92]:44124) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZaS6B-0006jy-JZ for 21127-done@debbugs.gnu.org; Fri, 11 Sep 2015 13:26:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZaS68-0005NZ-Cg for 21127-done@debbugs.gnu.org; Fri, 11 Sep 2015 13:26:55 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,T_RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:46531) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZaS68-0005NV-9t; Fri, 11 Sep 2015 13:26:52 -0400 Received: from reverse-83.fdn.fr ([80.67.176.83]:50144 helo=pluto) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1ZaS67-0000lN-MH; Fri, 11 Sep 2015 13:26:52 -0400 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) To: Mathieu Lirzin Subject: Re: bug#21127: Problem with guix.el on hybrid systems. References: <876159eo9i.fsf@openmailbox.org> Date: Fri, 11 Sep 2015 19:26:49 +0200 In-Reply-To: <876159eo9i.fsf@openmailbox.org> (Mathieu Lirzin's message of "Fri, 24 Jul 2015 14:25:13 +0200") Message-ID: <87io7gc1eu.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 21127-done Cc: 21127-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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: -5.0 (-----) Mathieu Lirzin skribis: F> So my current fix is to add (setq guix-guile-program "/usr/bin/guile") > to my .emacs file, then everything works fine. But what should we do to > avoid such thing? AIUI we could document it in > (info "(guix)Application Setup") or (info "(guix)Emacs Initial Setup"), > or even better fix it directly in the code (if possible). > > Here is my attempt to fix the code with my na=C3=AFve elisp programming. = I > would be happy to get better suggestion! This bug was fixed in 7061938, so closing it. Thanks, Ludo=E2=80=99. From unknown Sun Jun 22 17:10:53 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sat, 10 Oct 2015 11:24:05 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator