unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Lynn Winebarger <owinebar@gmail.com>
Cc: Eli Zaretskii <eliz@gnu.org>,  Po Lu <luangruo@yahoo.com>,
	 emacs-devel <emacs-devel@gnu.org>
Subject: Re: Docstring hack
Date: Sun, 31 Jul 2022 17:32:27 -0400	[thread overview]
Message-ID: <jwvk07tq8kv.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <CAM=F=bCKGozhWDmFGQ0U7X69vJhR7+4Fmzf=3C45giW_RfNDpg@mail.gmail.com> (Lynn Winebarger's message of "Sun, 31 Jul 2022 08:43:09 -0400")

> mode, then that is overkill.  I don't understand why the docstrings are
> even being extracted for the byte compiled files at all, since they would
> be lazy loaded anyway.  Then you could remove the files from lisp.mk from
> the dependencies of DOC in the Makefile and just leave loaddefs and the
> docstrings from C source files.

That's indeed what we in Emacs-29.

> This is the conundrum of trying to do anything significant in site-load
> without Makefile support.  If you're bootstrapping, then none of those
> files are compiled.  So I put in a check to only load after the bootstrap
> during the dump. But nothing is byte compiled at this point other than the
> files in loadup.  Trying to do the byte compile from within site-load after
> the bootstrap but during the dump requires pre loading the source of all
> dependencies, because require and autoload hit the panic button in dump
> mode.

Loading `site-load.el` in the first dump is a bad idea because files
haven't been compiled yet.

Loading `site-load.el` in the second dump is a bad idea because:
- as currently written, the site-loaded files aren't compiled, so it's
  too early to dump them.
- if you change the build to byte-compile them before the second dump,
  you'll be byte-compiling them with the bootstrap-emacs which might
  work but will lead to a slower compilation.

So, I suggest something like:

    mv lisp/site-load.el lisp/my-site-load.el
    make
    rm src/emacs
    mv lisp/my-site-load.el  lisp/site-load.el
    mv lisp/my-site-load.elc lisp/site-load.elc
    make

So the first 2 dumps are "normal" without any site-loaded files, and
that's followed by a 3rd dump, where all the ELisp files are already
byte-compiled.


        Stefan




  reply	other threads:[~2022-07-31 21:32 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-30 12:14 Docstring hack Lynn Winebarger
2022-07-30 12:25 ` Po Lu
2022-07-30 12:50   ` Lynn Winebarger
2022-07-30 13:04     ` Lynn Winebarger
2022-07-30 13:32     ` Po Lu
2022-07-30 13:28 ` Eli Zaretskii
2022-07-30 13:36   ` Po Lu
2022-07-30 15:11     ` Eli Zaretskii
2022-07-30 15:38       ` Lynn Winebarger
2022-07-30 15:44         ` Eli Zaretskii
2022-07-30 16:32           ` Lynn Winebarger
2022-07-30 16:43             ` Eli Zaretskii
2022-07-31  2:17               ` Po Lu
2022-07-31  6:27                 ` Eli Zaretskii
2022-07-31  7:24                   ` Po Lu
2022-07-31  7:56                     ` Eli Zaretskii
2022-07-31  8:48                       ` Po Lu
2022-07-31  9:14                         ` Lars Ingebrigtsen
2022-07-31 22:31                           ` Stefan Monnier
2022-08-01 10:38                             ` Lars Ingebrigtsen
2022-08-04  4:12                         ` Lynn Winebarger
2022-07-31 12:53                       ` Lynn Winebarger
2022-07-31 13:05                         ` Eli Zaretskii
2022-07-31 20:29                           ` Lynn Winebarger
2022-08-01  1:05                             ` Po Lu
2022-08-01 11:07                             ` Eli Zaretskii
2022-07-31  8:03                   ` Stefan Monnier
2022-07-31 12:43                     ` Lynn Winebarger
2022-07-31 21:32                       ` Stefan Monnier [this message]
2022-08-02 16:55                         ` Lynn Winebarger
2022-07-31 11:57               ` Lynn Winebarger
2022-07-31  0:52       ` Po Lu
2022-07-31  7:52     ` Stefan Monnier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=jwvk07tq8kv.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=luangruo@yahoo.com \
    --cc=owinebar@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).