]> git.eshelyaron.com Git - emacs.git/commitdiff
Call enchant-lsmod correctly when Enchant is installed with a suffix
authorReuben Thomas <rrt@sc3d.org>
Fri, 16 Mar 2018 10:50:21 +0000 (10:50 +0000)
committerReuben Thomas <rrt@sc3d.org>
Fri, 16 Mar 2018 10:50:21 +0000 (10:50 +0000)
* lisp/textmodes/ispell.el (ispell--call-enchant-lsmod): Cope with a
version suffix on the binary name, so enchant-2 is converted to
enchant-lsmod-2, not enchant-2-lsmod.

lisp/textmodes/ispell.el

index 512dfcfa6a7adf63f8da31491cefda4576585c01..ba98ea5519966ca1bdf9a8e6fa1e3a3a9c9d5c7f 100644 (file)
@@ -1200,8 +1200,9 @@ Internal use.")
   (with-output-to-string
     (with-current-buffer
         standard-output
-        (apply 'ispell-call-process
-               (concat ispell-program-name "-lsmod") nil t nil args))))
+      (apply 'ispell-call-process
+             (replace-regexp-in-string "enchant\\(-[0-9]\\)?$" "enchant-lsmod\\1"
+                                       ispell-program-name) nil t nil args))))
 
 (defun ispell--get-extra-word-characters (&optional lang)
   "Get the extra word characters for LANG as a character class.