From: Paul Eggert <eggert@cs.ucla.edu>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: 53358-done@debbugs.gnu.org
Subject: bug#53358: 29.0.50; Compilation output messed up again
Date: Fri, 21 Jan 2022 14:52:50 -0800 [thread overview]
Message-ID: <1c8120a3-0929-14a5-cce5-a03188a06ab8@cs.ucla.edu> (raw)
In-Reply-To: <87czklwidx.fsf@gnus.org>
[-- Attachment #1: Type: text/plain, Size: 553 bytes --]
On 1/21/22 01:24, Lars Ingebrigtsen wrote:
> I see it on every build I do (8 core machine, 16 threads, so I use
> -j16).
Ah, your machine is beefier than mine.
I installed the attached to attempt to implement your suggestion to use
an 'echo' workaround only for "ELC"-like lines. Please give it a try.
The workaround is used only for current (and older) versions of GNU
Make, so it will phase itself out eventually. In the meantime I can use
bleeding-edge Make to debug without worrying about the extra processes
generated by the 'echo' approach.
[-- Attachment #2: 0001-Simplify-AM_V_ELC-setup.patch --]
[-- Type: text/x-patch, Size: 1329 bytes --]
From 882bbeb1f9f40ccf9f1e3f3423fd7cb12a4859ab Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert@cs.ucla.edu>
Date: Fri, 21 Jan 2022 13:33:55 -0800
Subject: [PATCH 1/2] Simplify AM_V_ELC setup
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
* src/verbose.mk.in (AM_V_ELC, AM_V_ELN): Use simpler Make ‘if’s.
---
src/verbose.mk.in | 12 +-----------
1 file changed, 1 insertion(+), 11 deletions(-)
diff --git a/src/verbose.mk.in b/src/verbose.mk.in
index 01076df946..c0bf67abd4 100644
--- a/src/verbose.mk.in
+++ b/src/verbose.mk.in
@@ -39,23 +39,13 @@ AM_V_CC = @$(info $ CC $@)
AM_V_CXX = @$(info $ CXX $@)
AM_V_CCLD = @$(info $ CCLD $@)
AM_V_CXXLD = @$(info $ CXXLD $@)
-ifeq ($(HAVE_NATIVE_COMP),yes)
-ifneq ($(NATIVE_DISABLED),1)
-ifneq ($(ANCIENT),yes)
+ifeq ($(HAVE_NATIVE_COMP)-$(NATIVE_DISABLED)-$(ANCIENT),yes--)
AM_V_ELC = @$(info $ ELC+ELN $@)
AM_V_ELN = @$(info $ ELN $@)
else
AM_V_ELC = @$(info $ ELC $@)
AM_V_ELN =
endif
-else
-AM_V_ELC = @$(info $ ELC $@)
-AM_V_ELN =
-endif
-else
-AM_V_ELC = @$(info $ ELC $@)
-AM_V_ELN =
-endif
AM_V_GEN = @$(info $ GEN $@)
AM_V_GLOBALS = @$(info $ GEN globals.h)
AM_V_NO_PD = --no-print-directory
--
2.32.0
[-- Attachment #3: 0002-Avoid-glitches-in-ELC-lines-in-build-output.patch --]
[-- Type: text/x-patch, Size: 2068 bytes --]
From fac8d0ac2f4cbdbd5828a57ddc90adf6601d956b Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert@cs.ucla.edu>
Date: Fri, 21 Jan 2022 14:45:57 -0800
Subject: [PATCH 2/2] Avoid glitches in ELC lines in build output
* src/verbose.mk.in (have_working_info): New macro.
(AM_V_ELC, AM_V_ELN): Use 'echo' rather than $(info ...)
on buggy versions of GNU Make.
---
src/verbose.mk.in | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)
diff --git a/src/verbose.mk.in b/src/verbose.mk.in
index c0bf67abd4..eb99e42695 100644
--- a/src/verbose.mk.in
+++ b/src/verbose.mk.in
@@ -33,19 +33,45 @@ AM_V_GLOBALS =
AM_V_NO_PD =
AM_V_RC =
else
+
+# Whether $(info ...) works. This is to work around a bug in GNU Make
+# 4.3 and earlier, which implements $(info MSG) via two system calls
+# { write (..., "MSG", 3); write (..., "\n", 1); }
+# which looks bad when make -j interleaves two of these at about the same time.
+#
+# Later versions of GNU Make have the 'notintermediate' feature,
+# so assume that $(info ...) works if this feature is present.
+#
+have_working_info = $(filter notintermediate,$(value .FEATURES))
+#
+# The workaround is to use the shell and 'echo' rather than $(info ...).
+# The workaround is done only for AM_V_ELC and AM_V_ELN,
+# since the bug is not annoying elsewhere.
+
AM_V_AR = @$(info $ AR $@)
AM_V_at = @
AM_V_CC = @$(info $ CC $@)
AM_V_CXX = @$(info $ CXX $@)
AM_V_CCLD = @$(info $ CCLD $@)
AM_V_CXXLD = @$(info $ CXXLD $@)
+
ifeq ($(HAVE_NATIVE_COMP)-$(NATIVE_DISABLED)-$(ANCIENT),yes--)
+ifdef have_working_info
AM_V_ELC = @$(info $ ELC+ELN $@)
AM_V_ELN = @$(info $ ELN $@)
else
+AM_V_ELC = @echo " ELC+ELN " $@;
+AM_V_ELN = @echo " ELN " $@;
+endif
+else
+ifdef have_working_info
AM_V_ELC = @$(info $ ELC $@)
+else
+AM_V_ELC = @echo " ELC " $@;
+endif
AM_V_ELN =
endif
+
AM_V_GEN = @$(info $ GEN $@)
AM_V_GLOBALS = @$(info $ GEN globals.h)
AM_V_NO_PD = --no-print-directory
--
2.32.0
next prev parent reply other threads:[~2022-01-21 22:52 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-19 8:20 bug#53358: 29.0.50; Compilation output messed up again Lars Ingebrigtsen
2022-01-19 8:36 ` Lars Ingebrigtsen
2022-01-19 9:07 ` Eli Zaretskii
2022-01-19 9:16 ` Lars Ingebrigtsen
2022-01-19 23:32 ` Paul Eggert
2022-01-19 23:53 ` Paul Eggert
2022-01-20 8:10 ` Lars Ingebrigtsen
2022-01-20 18:21 ` Paul Eggert
2022-01-21 9:24 ` Lars Ingebrigtsen
2022-01-21 22:52 ` Paul Eggert [this message]
2022-01-22 10:16 ` Lars Ingebrigtsen
2022-01-24 7:25 ` Paul Eggert
2022-01-24 9:47 ` 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
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=1c8120a3-0929-14a5-cce5-a03188a06ab8@cs.ucla.edu \
--to=eggert@cs.ucla.edu \
--cc=53358-done@debbugs.gnu.org \
--cc=larsi@gnus.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 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).