unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Konstantin Kharlamov <Hi-Angel@yandex.ru>
To: Eli Zaretskii <eliz@gnu.org>
Cc: gerd.moellmann@gmail.com, acm@muc.de, 74382@debbugs.gnu.org
Subject: bug#74382: `compile-first` Make rule is no longer using `load-prefer-newer`
Date: Sun, 17 Nov 2024 19:04:42 +0300	[thread overview]
Message-ID: <a5448e8a48a03fb124af75d337b417da098f81ec.camel@yandex.ru> (raw)
In-Reply-To: <86zflxvoux.fsf@gnu.org>

On Sun, 2024-11-17 at 17:53 +0200, Eli Zaretskii wrote:
> > From: Konstantin Kharlamov <Hi-Angel@yandex.ru>
> > Cc: gerd.moellmann@gmail.com, acm@muc.de, 74382@debbugs.gnu.org
> > Date: Sun, 17 Nov 2024 18:43:17 +0300
> > 
> > On Sun, 2024-11-17 at 17:37 +0200, Eli Zaretskii wrote:
> > > > Cc: Alan Mackenzie <acm@muc.de>, 74382@debbugs.gnu.org
> > > > From: Konstantin Kharlamov <Hi-Angel@yandex.ru>
> > > > Date: Sun, 17 Nov 2024 18:21:36 +0300
> > > > 
> > > > On Sun, 2024-11-17 at 08:25 +0100, Gerd Möllmann wrote:
> > > > > Konstantin Kharlamov <Hi-Angel@yandex.ru> writes:
> > > > > 
> > > > > > Sure, I just reproduced it after removing all `.elc` files
> > > > > > in
> > > > > > the
> > > > > > repo,
> > > > > > here how:
> > > > > > 
> > > > > > 1. `git checkout f2f13fa630b` (a commit from April)
> > > > > > 2. `make -j$(nproc)` to compile. Note: you don't need to
> > > > > > wait
> > > > > > for
> > > > > > build
> > > > > > to finish, I just waited for all files under `lisp/emacs-
> > > > > > lisp`
> > > > > > directory to finish compilation, and then ^C'ed it.
> > > > > > 3. `git checkout 29098a291f5` (a November commit).
> > > > > > 4. `make -j$(nproc)`
> > > > > 
> > > > > This would always work if lisp/Makefile would rm the .elc
> > > > > files
> > > > > from
> > > > > COMPILE_FIRST, right? I suspect this isn't done to speed up
> > > > > the
> > > > > build
> > > > > in
> > > > > the usual case, and because it's a bit difficult to
> > > > > automatically
> > > > > determine if it has to done or not.
> > > > > 
> > > > > Does a "make clean" after the checkout in (3) make it work?
> > > > 
> > > > I don't think so, because `make clean` for some reason doesn't
> > > > remove
> > > > `.elc` artifacts.
> > > 
> > > And it shouldn't, because *.elc files are part of a release
> > > tarball.
> > 
> > But if someone decided to build from a release tarball, sure they
> > can
> > produce .elc files as well, can't they?
> 
> No, Emacs release tarballs come with *.elc files, and users shouldn't
> recompile them.  For starters, it makes the build significantly
> longer, besides being unnecessary.
> 
> Recompiling *.elc files is only needed if the corresponding *.el
> files
> are modified, something that doesn't normally happen when you build a
> release tarball.

Okay. So, how about a compromise here: provide release tarball with
modified Makefiles which upon calling `make clean` would not remove
`.elc` files — but let `make clean` inside git-repository remove elc
files?

Users expect `make clean` to remove non-config-related bulid artifacts.
Which includes `.elc` files. I can't count how many times I was
forgetting about this peculiarity of Emacs build system, and after
finding out that even `make clean` doesn't help with build errors (due
to COMPILE_FIRST files stuff), I had to nuke everything with `git clean
-fdx`. Even Gerd in this discussion forgot about this peculiarity — and
Gerd unlike me is a regular Emacs developer.





  reply	other threads:[~2024-11-17 16:04 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-16 15:11 bug#74382: `compile-first` Make rule is no longer using `load-prefer-newer` Konstantin Kharlamov
2024-11-16 16:27 ` Eli Zaretskii
2024-11-16 16:53 ` Alan Mackenzie
2024-11-16 17:45   ` Konstantin Kharlamov
2024-11-16 18:38     ` Eli Zaretskii
2024-11-16 18:43       ` Konstantin Kharlamov
2024-11-16 20:00         ` Eli Zaretskii
2024-11-16 22:54           ` Konstantin Kharlamov
2024-11-17  6:44             ` Eli Zaretskii
2024-11-17 15:31               ` Konstantin Kharlamov
2024-11-17  7:25     ` Gerd Möllmann
2024-11-17 15:21       ` Konstantin Kharlamov
2024-11-17 15:37         ` Eli Zaretskii
2024-11-17 15:43           ` Konstantin Kharlamov
2024-11-17 15:53             ` Eli Zaretskii
2024-11-17 16:04               ` Konstantin Kharlamov [this message]
2024-11-17 16:29                 ` Eli Zaretskii
2024-11-17 16:46                   ` Konstantin Kharlamov
2024-11-17 17:09                     ` Eli Zaretskii
2024-11-17 17:24                       ` Konstantin Kharlamov
2024-11-18  4:06                 ` Gerd Möllmann
2024-11-18  6:19                   ` Konstantin Kharlamov
2024-11-18 10:05                   ` Konstantin Kharlamov
2024-11-18 12:59                     ` Eli Zaretskii
2024-11-18 13:12                       ` Konstantin Kharlamov
2024-11-18 13:38                         ` Eli Zaretskii
2024-11-17 15:43         ` Gerd Möllmann

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=a5448e8a48a03fb124af75d337b417da098f81ec.camel@yandex.ru \
    --to=hi-angel@yandex.ru \
    --cc=74382@debbugs.gnu.org \
    --cc=acm@muc.de \
    --cc=eliz@gnu.org \
    --cc=gerd.moellmann@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).