Mercurial > emacs
comparison lisp/eshell/esh-module.el @ 31327:02375e0f6ea7
(eval-when-compile): Don't lose if esh-module.el's file name
is truncated to DOS 8+3 limits.
author | Eli Zaretskii <eliz@gnu.org> |
---|---|
date | Sat, 02 Sep 2000 05:34:42 +0000 |
parents | 570efb22ec0b |
children | b09ded79f0f9 |
comparison
equal
deleted
inserted
replaced
31326:a36c3cf583d4 | 31327:02375e0f6ea7 |
---|---|
71 ;; documentation can be provided when the user customize's | 71 ;; documentation can be provided when the user customize's |
72 ;; `eshell-modules-list'. | 72 ;; `eshell-modules-list'. |
73 (eval-when-compile | 73 (eval-when-compile |
74 (when (and (boundp 'byte-compile-current-file) | 74 (when (and (boundp 'byte-compile-current-file) |
75 byte-compile-current-file | 75 byte-compile-current-file |
76 (equal (file-name-nondirectory byte-compile-current-file) | 76 (or |
77 "esh-module.el")) | 77 (equal (file-name-nondirectory byte-compile-current-file) |
78 "esh-module.el") | |
79 ;; When eshell file names are expanded from a wildcard | |
80 ;; or by reading the Eshell directory, e.g. when they | |
81 ;; say "make recompile" in the lisp directory, Emacs on | |
82 ;; MS-DOS sees a truncated name "esh-modu.el" instead of | |
83 ;; "esh-module.el". | |
84 (and (fboundp 'msdos-long-file-names) | |
85 (null (msdos-long-file-names)) | |
86 (equal (file-name-nondirectory byte-compile-current-file) | |
87 "esh-modu.el")))) | |
78 (let* ((directory (file-name-directory byte-compile-current-file)) | 88 (let* ((directory (file-name-directory byte-compile-current-file)) |
79 (elc-file (expand-file-name "esh-groups.elc" directory))) | 89 (elc-file (expand-file-name "esh-groups.elc" directory))) |
80 (eshell-load-defgroups directory) | 90 (eshell-load-defgroups directory) |
81 (if (file-exists-p elc-file) (delete-file elc-file))))) | 91 (if (file-exists-p elc-file) (delete-file elc-file))))) |
82 | 92 |