summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
diff options
context:
space:
mode:
authorJim Porter <jporterbugs@gmail.com>2023-07-31 23:10:03 -0700
committerJim Porter <jporterbugs@gmail.com>2023-08-01 18:14:35 -0700
commitda5e05a50e8713f5efb51567645822fa5bfdd6b7 (patch)
tree3570eaca7e25a0b33777e5a83d7aceaa0b7aae6b /lisp/emacs-lisp
parent608a8757d9fa54bc2fd57180b0347931db9c46b0 (diff)
downloademacs-da5e05a50e8713f5efb51567645822fa5bfdd6b7.tar.gz
emacs-da5e05a50e8713f5efb51567645822fa5bfdd6b7.tar.bz2
emacs-da5e05a50e8713f5efb51567645822fa5bfdd6b7.zip
Fix handling of ".elpaignore" file when compiling packages
* lisp/emacs-lisp/bytecomp.el (byte-recompile-directory): Treat 'byte-compile-ignore-files' as a list of regexps per its docstring (bug#64985).
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r--lisp/emacs-lisp/bytecomp.el10
1 files changed, 4 insertions, 6 deletions
diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el
index 5df1205869c..65ccb60726f 100644
--- a/lisp/emacs-lisp/bytecomp.el
+++ b/lisp/emacs-lisp/bytecomp.el
@@ -1922,6 +1922,8 @@ also be compiled."
(emacs-lisp-compilation-mode))
(let ((directories (list default-directory))
(default-directory default-directory)
+ (ignore-files-regexp
+ (mapconcat #'identity byte-compile-ignore-files "\\|"))
(skip-count 0)
(fail-count 0)
(file-count 0)
@@ -1942,9 +1944,7 @@ also be compiled."
(or (null arg) (eq 0 arg)
(y-or-n-p (concat "Check " source "? ")))
;; Directory is requested to be ignored
- (not (string-match-p
- (regexp-opt byte-compile-ignore-files)
- source))
+ (not (string-match-p ignore-files-regexp source))
(setq directories (nconc directories (list source))))
;; It is an ordinary file. Decide whether to compile it.
(if (and (string-match emacs-lisp-file-regexp source)
@@ -1954,9 +1954,7 @@ also be compiled."
(not (auto-save-file-name-p source))
(not (member source (dir-locals--all-files directory)))
;; File is requested to be ignored
- (not (string-match-p
- (regexp-opt byte-compile-ignore-files)
- source)))
+ (not (string-match-p ignore-files-regexp source)))
(progn (cl-incf
(pcase (byte-recompile-file source force arg)
('no-byte-compile skip-count)