From dab5768422ba1c3cf66cad5d2708d390be87e3d0 Mon Sep 17 00:00:00 2001 From: Bastien Date: Thu, 1 Dec 2022 08:16:13 +0100 Subject: [PATCH] Autoload `org-assert-version' and remove org-loaddefs.el `org-assert-version' macro needs to be autoloaded for Org to be correctly initialized. Also, don't create a specific org-loaddefs.el file along the expected org-autoloads.el. --- Makefile | 2 +- doc/org-manual.org | 3 +-- lisp/Makefile | 4 ++-- lisp/ob-core.el | 4 ---- lisp/ob-lob.el | 4 ---- lisp/ob-tangle.el | 4 ---- lisp/ob.el | 4 ---- lisp/ol-bbdb.el | 4 ---- lisp/ol-irc.el | 4 ---- lisp/ol.el | 4 ---- lisp/org-archive.el | 4 ---- lisp/org-attach.el | 4 ---- lisp/org-clock.el | 1 - lisp/org-colview.el | 5 ----- lisp/org-compat.el | 5 +---- lisp/org-datetree.el | 4 ---- lisp/org-duration.el | 4 ---- lisp/org-element.el | 4 ---- lisp/org-feed.el | 4 ---- lisp/org-footnote.el | 5 ----- lisp/org-goto.el | 4 ---- lisp/org-id.el | 4 ---- lisp/org-indent.el | 4 ---- lisp/org-keys.el | 4 ---- lisp/org-lint.el | 4 ---- lisp/org-list.el | 4 ---- lisp/org-macs.el | 5 +---- lisp/org-mobile.el | 4 ---- lisp/org-num.el | 4 ---- lisp/org-plot.el | 4 ---- lisp/org-refile.el | 4 ---- lisp/org-table.el | 4 ---- lisp/org-timer.el | 4 ---- lisp/org.el | 10 +++++----- lisp/ox-ascii.el | 2 -- lisp/ox-beamer.el | 4 ---- lisp/ox-html.el | 5 ----- lisp/ox-icalendar.el | 5 ----- lisp/ox-latex.el | 5 ----- lisp/ox-md.el | 4 ---- lisp/ox-odt.el | 4 ---- lisp/ox-org.el | 5 ----- lisp/ox-publish.el | 4 ---- lisp/ox-texinfo.el | 4 ---- lisp/ox.el | 6 ------ mk/default.mk | 6 +++--- mk/org-fixup.el | 16 ++++++++-------- 47 files changed, 22 insertions(+), 188 deletions(-) diff --git a/Makefile b/Makefile index f476a3ea7..601f691eb 100644 --- a/Makefile +++ b/Makefile @@ -27,7 +27,7 @@ help helpall:: $(info make all - ditto) $(info make compile - build Org ELisp files) $(info make single - build Org ELisp files, single Emacs per source) - $(info make autoloads - create org-loaddefs.el to load Org in-place) + $(info make autoloads - create org-autoloads.el to load Org in-place) $(info make test - build Org ELisp files and run test suite) $(info make vanilla - run Emacs with this Org-mode and no personal config) helpall:: diff --git a/doc/org-manual.org b/doc/org-manual.org index 67b8b4dee..4041c7253 100644 --- a/doc/org-manual.org +++ b/doc/org-manual.org @@ -3,7 +3,6 @@ #+author: The Org Mode Developers #+language: en - #+texinfo: @insertcopying * Introduction @@ -128,7 +127,7 @@ $ make autoloads Note that in this case, =make autoloads= is mandatory: it defines Org's version in =org-version.el= and Org's autoloads in -=org-loaddefs.el=. +=org-autoloads.el=. Make sure you set the load path correctly in your Emacs init file: diff --git a/lisp/Makefile b/lisp/Makefile index f2a14b5d5..0bf4e3ddb 100644 --- a/lisp/Makefile +++ b/lisp/Makefile @@ -15,7 +15,7 @@ ifneq ($(ORG_ADD_CONTRIB),) endif LISPV := org-version.el -LISPI := org-loaddefs.el +LISPI := org-autoloads.el LISPA := $(LISPV) $(LISPI) LISPB := $(LISPA:%el=%elc) org-install.elc LISPF := $(filter-out $(LISPA),$(sort $(wildcard *.el) $(_ORG_ADD_EL_))) @@ -72,7 +72,7 @@ $(LISPV): $(LISPF) @$(MAKE_ORG_VERSION) $(LISPI): $(LISPV) $(LISPF) - @echo "org-loaddefs: $(ORGVERSION) ($(GITVERSION))" + @echo "org-autoloads: $(ORGVERSION) ($(GITVERSION))" @$(RM) $(@) @$(MAKE_ORG_INSTALL) diff --git a/lisp/ob-core.el b/lisp/ob-core.el index 5b78ee946..7bc3fbf59 100644 --- a/lisp/ob-core.el +++ b/lisp/ob-core.el @@ -3467,8 +3467,4 @@ Callers of this function will probably want to add an entry to (provide 'ob-core) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ob-core.el ends here diff --git a/lisp/ob-lob.el b/lisp/ob-lob.el index fb2799755..ecbbe4fe3 100644 --- a/lisp/ob-lob.el +++ b/lisp/ob-lob.el @@ -167,8 +167,4 @@ see." (provide 'ob-lob) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ob-lob.el ends here diff --git a/lisp/ob-tangle.el b/lisp/ob-tangle.el index e86f4e528..b93becfe4 100644 --- a/lisp/ob-tangle.el +++ b/lisp/ob-tangle.el @@ -691,8 +691,4 @@ which enable the original code blocks to be found." (provide 'ob-tangle) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ob-tangle.el ends here diff --git a/lisp/ob.el b/lisp/ob.el index 83fc5b23e..56bf9693b 100644 --- a/lisp/ob.el +++ b/lisp/ob.el @@ -40,8 +40,4 @@ (provide 'ob) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ob.el ends here diff --git a/lisp/ol-bbdb.el b/lisp/ol-bbdb.el index ec1d755e8..72b115d03 100644 --- a/lisp/ol-bbdb.el +++ b/lisp/ol-bbdb.el @@ -542,8 +542,4 @@ END:VEVENT\n" (provide 'ol-bbdb) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ol-bbdb.el ends here diff --git a/lisp/ol-irc.el b/lisp/ol-irc.el index 25d11ca13..82f1fc799 100644 --- a/lisp/ol-irc.el +++ b/lisp/ol-irc.el @@ -265,8 +265,4 @@ FORMAT." (provide 'ol-irc) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ol-irc.el ends here diff --git a/lisp/ol.el b/lisp/ol.el index 0b4457b00..b6ff01593 100644 --- a/lisp/ol.el +++ b/lisp/ol.el @@ -2101,8 +2101,4 @@ Also refresh fontification if needed." (provide 'ol) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ol.el ends here diff --git a/lisp/org-archive.el b/lisp/org-archive.el index d08afa457..80dddc694 100644 --- a/lisp/org-archive.el +++ b/lisp/org-archive.el @@ -642,8 +642,4 @@ This command is set with the variable `org-archive-default-command'." (provide 'org-archive) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-archive.el ends here diff --git a/lisp/org-attach.el b/lisp/org-attach.el index f85811dc7..bd262edd6 100644 --- a/lisp/org-attach.el +++ b/lisp/org-attach.el @@ -830,8 +830,4 @@ Idea taken from `gnus-dired-attach'." (provide 'org-attach) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-attach.el ends here diff --git a/lisp/org-clock.el b/lisp/org-clock.el index 2758aeed4..df4c519d2 100644 --- a/lisp/org-clock.el +++ b/lisp/org-clock.el @@ -3181,7 +3181,6 @@ This function is added to `kill-emacs-query-functions'." (provide 'org-clock) ;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" ;; coding: utf-8 ;; End: diff --git a/lisp/org-colview.el b/lisp/org-colview.el index 20bf2b7e9..4c178b526 100644 --- a/lisp/org-colview.el +++ b/lisp/org-colview.el @@ -1732,11 +1732,6 @@ This will add overlays to the date lines, to show the summary for each day." (equal (nth 3 a) (nth 3 spec)))) (org-columns-compute prop)))))))))) - (provide 'org-colview) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-colview.el ends here diff --git a/lisp/org-compat.el b/lisp/org-compat.el index 2f29754f1..5382eb572 100644 --- a/lisp/org-compat.el +++ b/lisp/org-compat.el @@ -1610,10 +1610,7 @@ key." (make-obsolete-variable 'org-speed-commands-user "configure `org-speed-commands' instead." "9.5") -(provide 'org-compat) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: +(provide 'org-compat) ;;; org-compat.el ends here diff --git a/lisp/org-datetree.el b/lisp/org-datetree.el index fb4df3cbe..7daca2ca9 100644 --- a/lisp/org-datetree.el +++ b/lisp/org-datetree.el @@ -265,8 +265,4 @@ before running this command, even though the command tries to be smart." (provide 'org-datetree) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-datetree.el ends here diff --git a/lisp/org-duration.el b/lisp/org-duration.el index 6d6b8b5cf..c037a5154 100644 --- a/lisp/org-duration.el +++ b/lisp/org-duration.el @@ -457,8 +457,4 @@ with \"H:MM:SS\" format, return `h:mm:ss'. Otherwise, return (provide 'org-duration) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-duration.el ends here diff --git a/lisp/org-element.el b/lisp/org-element.el index bc2fa0b98..c03d0ae59 100644 --- a/lisp/org-element.el +++ b/lisp/org-element.el @@ -8100,8 +8100,4 @@ end of ELEM-A." (provide 'org-element) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-element.el ends here diff --git a/lisp/org-feed.el b/lisp/org-feed.el index 3523a6c5b..b9889ce44 100644 --- a/lisp/org-feed.el +++ b/lisp/org-feed.el @@ -715,8 +715,4 @@ formatted as a string, not the original XML data." (provide 'org-feed) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-feed.el ends here diff --git a/lisp/org-footnote.el b/lisp/org-footnote.el index aedd41335..2f41e63bd 100644 --- a/lisp/org-footnote.el +++ b/lisp/org-footnote.el @@ -1016,11 +1016,6 @@ offer additional commands in a menu." (char (error "No such footnote command %c" char)))) (t (org-footnote-new))))) - (provide 'org-footnote) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-footnote.el ends here diff --git a/lisp/org-goto.el b/lisp/org-goto.el index 680130384..bf4f886f6 100644 --- a/lisp/org-goto.el +++ b/lisp/org-goto.el @@ -285,8 +285,4 @@ With a prefix argument, use the alternative interface: e.g., if (provide 'org-goto) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-goto.el ends here diff --git a/lisp/org-id.el b/lisp/org-id.el index 8cb5666a2..bfe341800 100644 --- a/lisp/org-id.el +++ b/lisp/org-id.el @@ -755,8 +755,4 @@ or filename if no title." (provide 'org-id) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-id.el ends here diff --git a/lisp/org-indent.el b/lisp/org-indent.el index de237415c..9c3c9eaca 100644 --- a/lisp/org-indent.el +++ b/lisp/org-indent.el @@ -430,8 +430,4 @@ This function is meant to be called by `after-change-functions'." (provide 'org-indent) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-indent.el ends here diff --git a/lisp/org-keys.el b/lisp/org-keys.el index 95f64a3f9..07aadb613 100644 --- a/lisp/org-keys.el +++ b/lisp/org-keys.el @@ -924,8 +924,4 @@ a-list placed behind the generic `org-babel-key-prefix'.") (provide 'org-keys) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-keys.el ends here diff --git a/lisp/org-lint.el b/lisp/org-lint.el index ff2999cb8..6eedf13df 100644 --- a/lisp/org-lint.el +++ b/lisp/org-lint.el @@ -1452,8 +1452,4 @@ Use \"export %s\" instead" (provide 'org-lint) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-lint.el ends here diff --git a/lisp/org-list.el b/lisp/org-list.el index 606bdb3d8..dd232dd86 100644 --- a/lisp/org-list.el +++ b/lisp/org-list.el @@ -3663,8 +3663,4 @@ overruling parameters for `org-list-to-generic'." (provide 'org-list) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-list.el ends here diff --git a/lisp/org-macs.el b/lisp/org-macs.el index 918899900..76b8b58c8 100644 --- a/lisp/org-macs.el +++ b/lisp/org-macs.el @@ -36,6 +36,7 @@ ;;; Org version verification. +;;;###autoload (defmacro org-assert-version () "Assert compile time and runtime version match." ;; We intentionally use a more permissive `org-release' instead of @@ -1561,8 +1562,4 @@ Credit: https://stackoverflow.com/questions/11871245/knuth-multiplicative-hash#4 (provide 'org-macs) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-macs.el ends here diff --git a/lisp/org-mobile.el b/lisp/org-mobile.el index a95c4e476..4c37300cd 100644 --- a/lisp/org-mobile.el +++ b/lisp/org-mobile.el @@ -1137,8 +1137,4 @@ A and B must be strings or nil." (provide 'org-mobile) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-mobile.el ends here diff --git a/lisp/org-num.el b/lisp/org-num.el index 4a57e6a9e..fa603d51a 100644 --- a/lisp/org-num.el +++ b/lisp/org-num.el @@ -473,8 +473,4 @@ NUMBERING is a list of numbers." (provide 'org-num) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-num.el ends here diff --git a/lisp/org-plot.el b/lisp/org-plot.el index ef6b5aa05..bc728288d 100644 --- a/lisp/org-plot.el +++ b/lisp/org-plot.el @@ -735,8 +735,4 @@ line directly before or after the table." (provide 'org-plot) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-plot.el ends here diff --git a/lisp/org-refile.el b/lisp/org-refile.el index 8c514b9d0..653bd73b8 100644 --- a/lisp/org-refile.el +++ b/lisp/org-refile.el @@ -758,8 +758,4 @@ this function appends the default value from (provide 'org-refile) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-refile.el ends here diff --git a/lisp/org-table.el b/lisp/org-table.el index 8e0e8e6cf..5df798b99 100644 --- a/lisp/org-table.el +++ b/lisp/org-table.el @@ -6368,8 +6368,4 @@ This function is generated by a call to the macro `org-define-lookup-function'." (provide 'org-table) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-table.el ends here diff --git a/lisp/org-timer.el b/lisp/org-timer.el index 9741ac679..103cbc5e8 100644 --- a/lisp/org-timer.el +++ b/lisp/org-timer.el @@ -489,8 +489,4 @@ Try to use an Org header, otherwise use the buffer name." (provide 'org-timer) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; org-timer.el ends here diff --git a/lisp/org.el b/lisp/org.el index a05a28229..0ee5a1510 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -84,10 +84,10 @@ (condition-case nil (load (concat (file-name-directory load-file-name) - "org-loaddefs") + "org-autoloads") nil t nil t) (error - (message "WARNING: No org-loaddefs.el file could be found from where org.el is loaded.") + (message "WARNING: No org-autoloads.el file could be found from where org.el is loaded.") (sit-for 3) (message "You need to run \"make\" or \"make autoloads\" from Org lisp directory") (sit-for 3))) @@ -364,7 +364,7 @@ FULL is given." (save-load-suffixes load-suffixes) (load-suffixes (list ".el")) (org-install-dir - (ignore-errors (org-find-library-dir "org-loaddefs")))) + (ignore-errors (org-find-library-dir "org-autoloads")))) (unless (and (fboundp 'org-release) (fboundp 'org-git-version)) (org-load-noerror-mustsuffix (concat org-dir "org-version"))) (let* ((load-suffixes save-load-suffixes) @@ -380,7 +380,7 @@ FULL is given." org-install-dir " and " org-dir)) - "org-loaddefs.el can not be found!"))) + "org-autoloads.el can not be found!"))) (version1 (if full version release))) (when here (insert version1)) (when message (message "%s" version1)) @@ -18261,7 +18261,7 @@ With prefix arg UNCOMPILED, load the uncompiled versions." (contrib-dir (or (org-find-library-dir "org-contribdir") org-dir)) (feature-re "^\\(org\\|ob\\|ox\\|ol\\|oc\\)\\(-.*\\)?") (remove-re (format "\\`%s\\'" - (regexp-opt '("org" "org-loaddefs" "org-version")))) + (regexp-opt '("org" "org-autoloads" "org-version")))) (feats (delete-dups (mapcar 'file-name-sans-extension (mapcar 'file-name-nondirectory diff --git a/lisp/ox-ascii.el b/lisp/ox-ascii.el index 7e5ba104f..b3c98cdb5 100644 --- a/lisp/ox-ascii.el +++ b/lisp/ox-ascii.el @@ -2210,11 +2210,9 @@ Return output file name." (org-publish-org-to 'ascii filename ".txt" `(:ascii-charset utf-8 ,@plist) pub-dir)) - (provide 'ox-ascii) ;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" ;; coding: utf-8 ;; End: diff --git a/lisp/ox-beamer.el b/lisp/ox-beamer.el index 51684448d..2a09f72db 100644 --- a/lisp/ox-beamer.el +++ b/lisp/ox-beamer.el @@ -1170,8 +1170,4 @@ Return output file name." (provide 'ox-beamer) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ox-beamer.el ends here diff --git a/lisp/ox-html.el b/lisp/ox-html.el index 86b10cbf7..060c7053c 100644 --- a/lisp/ox-html.el +++ b/lisp/ox-html.el @@ -4018,11 +4018,6 @@ Return output file name." "html")) plist pub-dir)) - (provide 'ox-html) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ox-html.el ends here diff --git a/lisp/ox-icalendar.el b/lisp/ox-icalendar.el index f4c904da4..d0045f614 100644 --- a/lisp/ox-icalendar.el +++ b/lisp/ox-icalendar.el @@ -1065,11 +1065,6 @@ FILES is a list of files to build the calendar from." org-icalendar-combined-agenda-file)) (org-release-buffers org-agenda-new-buffers)))) - (provide 'ox-icalendar) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ox-icalendar.el ends here diff --git a/lisp/ox-latex.el b/lisp/ox-latex.el index 46a348a68..fd92bb1a8 100644 --- a/lisp/ox-latex.el +++ b/lisp/ox-latex.el @@ -4348,11 +4348,6 @@ Return output file name." 'latex filename ".tex" plist (file-name-directory filename)))) pub-dir)) - (provide 'ox-latex) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ox-latex.el ends here diff --git a/lisp/ox-md.el b/lisp/ox-md.el index dee6dbf1f..0cadcbd88 100644 --- a/lisp/ox-md.el +++ b/lisp/ox-md.el @@ -802,8 +802,4 @@ Return output file name." (provide 'ox-md) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ox-md.el ends here diff --git a/lisp/ox-odt.el b/lisp/ox-odt.el index 402c75447..bd3f565ae 100644 --- a/lisp/ox-odt.el +++ b/lisp/ox-odt.el @@ -4350,8 +4350,4 @@ is non-nil then the newly converted file is opened using (provide 'ox-odt) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ox-odt.el ends here diff --git a/lisp/ox-org.el b/lisp/ox-org.el index 159a41b98..9b53136d5 100644 --- a/lisp/ox-org.el +++ b/lisp/ox-org.el @@ -350,11 +350,6 @@ Return output file name." ;; FIXME: Why? Which buffer is this supposed to apply to? (set-buffer-modified-p nil))) - (provide 'ox-org) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ox-org.el ends here diff --git a/lisp/ox-publish.el b/lisp/ox-publish.el index a5999ef7b..a3d8be517 100644 --- a/lisp/ox-publish.el +++ b/lisp/ox-publish.el @@ -1379,8 +1379,4 @@ does not exist." (provide 'ox-publish) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ox-publish.el ends here diff --git a/lisp/ox-texinfo.el b/lisp/ox-texinfo.el index 73ba349b1..3edca9b94 100644 --- a/lisp/ox-texinfo.el +++ b/lisp/ox-texinfo.el @@ -2046,8 +2046,4 @@ Once computed, the results remain cached." (provide 'ox-texinfo) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ox-texinfo.el ends here diff --git a/lisp/ox.el b/lisp/ox.el index 5c0a8f242..1daa97199 100644 --- a/lisp/ox.el +++ b/lisp/ox.el @@ -7248,12 +7248,6 @@ options as CDR." ;; Otherwise, enter sub-menu. (t (org-export--dispatch-ui options key expertp))))) - - (provide 'ox) -;; Local variables: -;; generated-autoload-file: "org-loaddefs.el" -;; End: - ;;; ox.el ends here diff --git a/mk/default.mk b/mk/default.mk index fa46661e8..d6e10b612 100644 --- a/mk/default.mk +++ b/mk/default.mk @@ -88,7 +88,7 @@ BTEST = $(BATCH) $(BTEST_INIT) \ $(lst-ob-lang)))) \ org-test-select-re "$(BTEST_RE)" \ )' \ - -l org-loaddefs.el \ + -l org-autoloads.el \ -l cl -l testing/org-test.el \ -l ert -l org -l ox -l ol \ $(foreach req,$(BTEST_EXTRA),$(req-extra)) \ @@ -136,11 +136,11 @@ MAKE_LOCAL_MK = $(BATCHO) \ BATCHL = $(BATCH) \ --eval '(add-to-list '"'"'load-path ".")' -# How to generate org-loaddefs.el +# How to generate org-autoloads.el MAKE_ORG_INSTALL = $(BATCHL) \ --eval '(load "org-compat.el")' \ --eval '(load "../mk/org-fixup.el")' \ - --eval '(org-make-org-loaddefs)' + --eval '(org-make-org-autoloads)' # How to generate org-version.el MAKE_ORG_VERSION = $(BATCHL) \ diff --git a/mk/org-fixup.el b/mk/org-fixup.el index 5989875a8..f1d21df15 100644 --- a/mk/org-fixup.el +++ b/mk/org-fixup.el @@ -80,27 +80,27 @@ Inserted by installing Org or when a release is made.\" (let ((inhibit-read-only t)) (write-file "org-version.el")))) -(defun org-make-org-loaddefs () - "Make the file org-loaddefs.el in the current directory. +(defun org-make-org-autoloads () + "Make the file org-autoloads.el in the current directory. This function is internally used by the build system and should be used by foreign build systems or installers to produce this file in the installation directory of Org mode. Org will not work correctly if this file is not up-to-date." (with-temp-buffer - (set-visited-file-name "org-loaddefs.el") - (insert ";;; org-loaddefs.el --- autogenerated file, do not edit\n;;\n;;; Code:\n") + (set-visited-file-name "org-autoloads.el") + (insert ";;; org-autoloads.el --- autogenerated file, do not edit\n;;\n;;; Code:\n") (let ((files (directory-files default-directory nil "^\\(org\\|ob\\|ox\\|ol\\|oc\\)\\(-.*\\)?\\.el$"))) (mapc (lambda (f) (generate-file-autoloads f)) files)) - (insert "\f\n(provide 'org-loaddefs)\n") + (insert "\f\n(provide 'org-autoloads)\n") (insert "\f\n;; Local Variables:\n;; version-control: never\n") (insert ";; no-byte-compile: t\n;; no-update-autoloads: t\n") - (insert ";; coding: utf-8\n;; End:\n;;; org-loaddefs.el ends here\n") + (insert ";; coding: utf-8\n;; End:\n;;; org-autoloads.el ends here\n") (let ((inhibit-read-only t)) (save-buffer)))) (defun org-make-autoloads (&optional compile force) - "Make the files org-loaddefs.el and org-version.el in the install directory. + "Make the files org-autoloads.el and org-version.el in the install directory. Finds the install directory by looking for library \"org\". Optionally byte-compile lisp files in the install directory or force re-compilation. This function is provided for easier @@ -112,7 +112,7 @@ manual install when the build system can't be used." (cd dirlisp) (org-fixup) (org-make-org-version (org-release) (org-git-version)) - (org-make-org-loaddefs) + (org-make-org-autoloads) (when compile (byte-recompile-directory dirlisp 0 force))) (cd origin)))) -- 2.37.2