]> git.eshelyaron.com Git - emacs.git/commitdiff
Allow specifying that loaddefs files shouldn't not be compiled
authorLars Ingebrigtsen <larsi@gnus.org>
Sun, 31 Jul 2022 17:57:55 +0000 (19:57 +0200)
committerLars Ingebrigtsen <larsi@gnus.org>
Sun, 31 Jul 2022 17:57:55 +0000 (19:57 +0200)
* lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate--rubric):
Allow specifying that we shouldn't include a no-compile cookie
(bug#53024).

lisp/emacs-lisp/loaddefs-gen.el

index 261e44aeced9de2fe6f9f6bc678a2c79da634d65..36b0b1e9cdf48878cfa081e83d6fc812feb71966 100644 (file)
@@ -459,7 +459,7 @@ don't include."
             (push name prefs)))))
     (loaddefs-generate--make-prefixes prefs load-name)))
 
-(defun loaddefs-generate--rubric (file &optional type feature)
+(defun loaddefs-generate--rubric (file &optional type feature compile)
   "Return a string giving the appropriate autoload rubric for FILE.
 TYPE (default \"autoloads\") is a string stating the type of
 information contained in FILE.  TYPE \"package\" acts like the default,
@@ -467,7 +467,9 @@ but adds an extra line to the output to modify `load-path'.
 
 If FEATURE is non-nil, FILE will provide a feature.  FEATURE may
 be a string naming the feature, otherwise it will be based on
-FILE's name."
+FILE's name.
+
+If COMPILE, don't include a \"don't compile\" cookie."
   (let ((lp (and (equal type "package") (setq type "autoloads"))))
     (with-temp-buffer
       (generate-lisp-file-heading
@@ -481,6 +483,7 @@ FILE's name."
       (insert "\f\n;;; End of scraped data\n\n")
       (generate-lisp-file-trailer
        file :provide (and (stringp feature) feature)
+       :compile compile
        :inhibit-provide (not feature))
       (buffer-string))))