aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1995-11-21 21:11:16 +0000
committerRichard M. Stallman1995-11-21 21:11:16 +0000
commit0bf659193de149eaaf2c3447c170243084443f1d (patch)
treeca5e3e8aed675e1fedaeee6b242fff33d03233d5
parentd07f802a2c5eb9d21356e1a70b76de78704dbd00 (diff)
downloademacs-0bf659193de149eaaf2c3447c170243084443f1d.tar.gz
emacs-0bf659193de149eaaf2c3447c170243084443f1d.zip
(Info-directory-list): Use source-directory.
-rw-r--r--lisp/info.el15
1 files changed, 10 insertions, 5 deletions
diff --git a/lisp/info.el b/lisp/info.el
index 2625e84beef..ed4f7ff11d3 100644
--- a/lisp/info.el
+++ b/lisp/info.el
@@ -54,8 +54,10 @@ The Lisp code is executed when the node is selected.")
54 ;; which might get this info.el from the Texinfo distribution. 54 ;; which might get this info.el from the Texinfo distribution.
55 (path-separator (if (boundp 'path-separator) path-separator 55 (path-separator (if (boundp 'path-separator) path-separator
56 (if (eq system-type 'ms-dos) ";" ":"))) 56 (if (eq system-type 'ms-dos) ";" ":")))
57 (source (expand-file-name "info/" source-directory))
57 (sibling (if installation-directory 58 (sibling (if installation-directory
58 (expand-file-name "info/" installation-directory)))) 59 (expand-file-name "info/" installation-directory)))
60 alternative)
59 (if path 61 (if path
60 (let ((list nil) 62 (let ((list nil)
61 idx) 63 idx)
@@ -65,9 +67,11 @@ The Lisp code is executed when the node is selected.")
65 path (substring path (min (1+ idx) 67 path (substring path (min (1+ idx)
66 (length path))))) 68 (length path)))))
67 (nreverse list)) 69 (nreverse list))
68 (if (or (null sibling) 70 (if (and sibling (file-exists-p sibling))
69 (member sibling Info-default-directory-list) 71 (setq alternative sibling)
70 (not (file-exists-p sibling)) 72 (setq alternative source))
73 (if (or (member alternative Info-default-directory-list)
74 (not (file-exists-p alternative))
71 ;; On DOS/NT, we use movable executables always, 75 ;; On DOS/NT, we use movable executables always,
72 ;; and we must always find the Info dir at run time. 76 ;; and we must always find the Info dir at run time.
73 (if (or (eq system-type 'ms-dos) (eq system-type 'windows-nt)) 77 (if (or (eq system-type 'ms-dos) (eq system-type 'windows-nt))
@@ -78,7 +82,8 @@ The Lisp code is executed when the node is selected.")
78 (expand-file-name "lib-src/" 82 (expand-file-name "lib-src/"
79 installation-directory))))) 83 installation-directory)))))
80 Info-default-directory-list 84 Info-default-directory-list
81 (reverse (cons sibling (cdr (reverse Info-default-directory-list))))))) 85 (reverse (cons alternative
86 (cdr (reverse Info-default-directory-list)))))))
82 "List of directories to search for Info documentation files. 87 "List of directories to search for Info documentation files.
83nil means not yet initialized. In this case, Info uses the environment 88nil means not yet initialized. In this case, Info uses the environment
84variable INFOPATH to initialize it, or `Info-default-directory-list' 89variable INFOPATH to initialize it, or `Info-default-directory-list'