summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Politz <politza@hochschule-trier.de>2017-09-14 10:22:25 +0200
committerAndreas Politz <politza@hochschule-trier.de>2017-09-14 10:23:02 +0200
commit5cf5ca4b5318f47f8aecc3acdefee21e81e1aac9 (patch)
tree8900b82e1840b34307c60a4e0f315037f99d302a
parent4f8c129ab636cd9afddae237bc3ab1aa2a136f19 (diff)
Look for epdfinfo in the Emacs's bin directory
-rw-r--r--lisp/pdf-info.el7
1 files changed, 7 insertions, 0 deletions
diff --git a/lisp/pdf-info.el b/lisp/pdf-info.el
index e7b3bf5..8d4ecc9 100644
--- a/lisp/pdf-info.el
+++ b/lisp/pdf-info.el
@@ -73,6 +73,13 @@
(file-executable-p (expand-file-name executable directory))
(expand-file-name executable directory))))
(or (executable-find executable)
+ ;; This works if epdfinfo is in the same place as emacs and
+ ;; the editor was started with an absolute path, i.e. it is
+ ;; ment for Windows/Msys2.
+ (and (stringp (car-safe command-line-args))
+ (file-name-directory (car command-line-args))
+ (try-directory
+ (file-name-directory (car command-line-args))))
(try-directory (expand-file-name "../server"))
(expand-file-name executable))))
"Filename of the epdfinfo executable."