Subject: Re: bug#79001: Retain profile image files generated during build

From: Lynn Winebarger <[email-masked]>
Date: Sat, 12 Jul 2025 23:31:18 -0400

On Sat, Jul 12, 2025 at 6:08 PM Lynn Winebarger <[email-masked]> wrote:
> However, in a parallel build, I am now seeing the cus-load.el target
> get run twice simultaneously, so that one instance will exit with a
> file lock error and stop the build.

I am not sure why the generate-ja-dic target in lisp/Makefile.in
depends on custom-deps, but that seems to be the cause of the race
condition.  At least the attached patch appears to eliminate the
problem (and the random segfaults for that matter) in a parallel make.

Lynn
From 74bd263d1f960ef9040dcb7db9651e3d52c2f151 Mon Sep 17 00:00:00 2001
From: Onnie Lynn Winebarger <[email-masked]>
Date: Sat, 12 Jul 2025 23:28:22 -0400
Subject: [PATCH 5/5] Removed race from generate-ja-dic dependency on
 custom-deps

---
 lisp/Makefile.in | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/Makefile.in b/lisp/Makefile.in
index 37c8ce73ea7..1d1ec5b1fd3 100644
--- a/lisp/Makefile.in
+++ b/lisp/Makefile.in
@@ -193,7 +193,7 @@ $(lisp)/finder-inf.el:
 	  -f finder-compile-keywords-make-dist ${SUBDIRS_FINDER}
 
 # This is the OKURO-NASI compilation trigger.
-generate-ja-dic: main-first custom-deps
+generate-ja-dic: main-first
 	$(AM_V_at)$(MAKE) -C ../leim generate-ja-dic EMACS="$(EMACS)" \
 		$(call set_gmon_prefix)
 	$(AM_V_at)$(MAKE) compile-targets TARGETS="./leim/ja-dic/ja-dic.elc" \
-- 
2.50.0