all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Dima Kogan <dima@secretsauce.net>
To: 48342@debbugs.gnu.org
Subject: bug#48342: native-comp emacs gets into an infinite loop at startup if no .el files are available
Date: Tue, 11 May 2021 00:47:10 -0700	[thread overview]
Message-ID: <878s4l1zlt.fsf@secretsauce.net> (raw)

Hi. I maintain Debian packages of bleeding-edge emacs builds:

  http://emacs.secretsauce.net/

Recently I enabled the native-comp flags for these packages. The results
mostly work, but a user sent me a bug report whose cause I just tracked
down. Some of this is probably my fault, as the packager, but there's an
emacs bug here too.

To tickle the bug the user needs to install the emacs-snapshot package,
but NOT the emacs-snapshot-el package. This results in the .elc files
being shipped, but NOT the .el files. This is a valid way to do it
without the native-comp patches, and the Debian emacs packages have
allowed this since forever.

If you install emacs like this, this happens:

  $ emacs-snapshot -Q -batch -f batch-native-compile empty.el

  Fatal error 11: Segmentation fault

The C backtrace is 6033 frames long, which can't be good. xbacktrace
says this:

  (gdb) xbacktrace
  "display-warning" (0xffebcfd8)
  "display-warning" (0xffebd5d8)
  .... lots more "display-warning"
  "locate-file" (0xffffe498)
  "command-line" (0xffffe5a0)
  "normal-top-level" (0xffffe640)

And the warning itself is:

  "Cannot look-up eln file as no source file was found for /usr/share/emacs/28.0.50/lisp/emacs-lisp/warnings.elc"

So something somewhere wanted to throw a warning, and this warning tried
to find its own sources, couldn't do it, and threw another warning. And
so on.

So first off, it'd be great if emacs could handle this without such a
recursive failure mode. It took me a long time to figure out what's
happening, and a plain-text error message on the console would have been
nice.

And second: how should this be packaged? Is shipping the .el files a
hard requirement now?

Thanks!





             reply	other threads:[~2021-05-11  7:47 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-11  7:47 Dima Kogan [this message]
2021-05-11  8:37 ` bug#48342: native-comp emacs gets into an infinite loop at startup if no .el files are available Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-05-11  8:44   ` Dima Kogan
2021-05-11 12:33     ` Eli Zaretskii
2021-05-11 17:00       ` Gregory Heytings
2021-05-11 17:12       ` Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-05-11 17:29       ` Dima Kogan
2021-05-11 17:43         ` Eli Zaretskii
2021-05-11 17:57           ` Dima Kogan
2021-05-11 18:57             ` Gregory Heytings
2021-05-11 19:11               ` Eli Zaretskii
2021-05-11 19:38                 ` Gregory Heytings
2021-05-11 19:51                   ` Eli Zaretskii
2021-05-11 19:59                     ` Dima Kogan
2021-05-11 20:23                       ` Eli Zaretskii
2021-05-11 20:00                     ` Gregory Heytings
2021-05-11 20:04                       ` Gregory Heytings
2021-05-11 17:45         ` Eli Zaretskii
2021-05-11 19:43           ` Andrea Corallo via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-02 16:44             ` Lars Ingebrigtsen

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

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

  git send-email \
    --in-reply-to=878s4l1zlt.fsf@secretsauce.net \
    --to=dima@secretsauce.net \
    --cc=48342@debbugs.gnu.org \
    /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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.