Hi Eric,

please consider the attached patch. Setting BUILD_VERBOSE to 1 in the
environment makes the build to be verbose with output to the console.

Regards

Carsten

>From a63bb05c614e49947ba0734000dbd8df8c2bb40c Mon Sep 17 00:00:00 2001
From: Carsten Leonhardt <l...@debian.org>
Date: Sat, 30 Nov 2024 13:01:09 +0100
Subject: [PATCH] Allow to toggle the build to verbose mode

Setting the environment variable BUILD_VERBOSE to 1 makes the build verbose.
---
 docs/Makefile         |  7 ++++++-
 docs/manuals/Makefile | 18 +++++++++++++++---
 2 files changed, 21 insertions(+), 4 deletions(-)

diff --git a/docs/Makefile b/docs/Makefile
index 09b99528..df4d402f 100644
--- a/docs/Makefile
+++ b/docs/Makefile
@@ -2,7 +2,12 @@
 #-------------------------------------------------------------------------
 SHELL = /bin/sh
 
-AT=@
+# if BUILD_VERBOSE is set to 1, output everything to the console
+ifeq ($(BUILD_VERBOSE),1)
+	AT=
+else
+	AT=@
+endif
 
 #
 # bacula.env file is a local file to define specific values if any
diff --git a/docs/manuals/Makefile b/docs/manuals/Makefile
index 212a9487..48f8beca 100644
--- a/docs/manuals/Makefile
+++ b/docs/manuals/Makefile
@@ -10,7 +10,13 @@ else
   $(error No environment file "$(MANUALENVFILE)" found. You can copy "$(MANUALENVFILE).dist" to "$(MANUALENVFILE)" and adjust some definitions.)
 endif
 
-AT=@
+# if BUILD_VERBOSE is set to 1, output everything to the console
+ifeq ($(BUILD_VERBOSE),1)
+	AT=
+else
+	AT=@
+endif
+
 #
 # WARNING !!! The following works *ONLY* when using MAKE with $(MAKE) -C subdir invocation.
 LICENCE_FILES=$(wildcard $(LICENCE_DIR)/*.tex)
@@ -24,8 +30,14 @@ WEB_FILES_TO_LINK=$(TRANSLATEIMGS) $(LATEX2HTMLINIT)
 PDFLATEX=$(COMPILER)
 PDFLATEXSILENT=batchmode
 PDFLATEXVERBOSE=errorstopmode
-PDFLATEXOPTIONS=-halt-on-error -interaction=$(PDFLATEXSILENT) # $(PDFLATEXVERBOSE) # 
-PDFOUTPUT="> $(DOC).out 2>&1"
+ifeq ($(BUILD_VERBOSE),1)
+	PDFLATEXOPTIONS=-halt-on-error -interaction=$(PDFLATEXVERBOSE)
+	PDFOUTPUT=""
+else
+	PDFLATEXOPTIONS=-halt-on-error -interaction=$(PDFLATEXSILENT)
+	PDFOUTPUT="> $(DOC).out 2>&1"
+endif
+
 #
 # Makefile used to produce HTML documentation
 EXTSEDFILES=html-external-references.sed
-- 
2.39.5

_______________________________________________
Bacula-devel mailing list
Bacula-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-devel

Reply via email to