From: Harald Nordgren via GitGitGadget Date: Sun, 14 Jun 2026 17:52:18 GMT Subject: [PATCH 1/2] gitk: silence catalog output under "make -s" Message-ID: <18451d46e431dec2ce3275d4837bd595298fc246.1781459539.git.gitgitgadget@gmail.com> In-Reply-To: From: Harald Nordgren The catalog rule unconditionally echoed "Generating catalog" and ran msgfmt with --statistics, whose output went to stderr and so survived "make -s". Emit the "Generating catalog" line and the msgfmt statistics only when "-s" is absent, leaving a quiet build silent while default and V=1 builds are unchanged. Signed-off-by: Harald Nordgren --- gitk-git/Makefile | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/gitk-git/Makefile b/gitk-git/Makefile index 41116d8a14..10078c54d4 100644 --- a/gitk-git/Makefile +++ b/gitk-git/Makefile @@ -43,10 +43,16 @@ PO_TEMPLATE = po/gitk.pot ALL_POFILES = $(wildcard po/*.po) ALL_MSGFILES = $(subst .po,.msg,$(ALL_POFILES)) +MSGFMT_GEN = @: + +ifneq ($(findstring s,$(firstword -$(MAKEFLAGS))),s) ifndef V QUIET = @ QUIET_GEN = $(QUIET)echo ' ' GEN $@ && endif + MSGFMT_GEN = @echo Generating catalog $@ + MSGFMT_STATS = --statistics +endif all:: gitk-wish $(ALL_MSGFILES) @@ -75,8 +81,8 @@ update-po:: $(PO_TEMPLATE) echo; \ echo " git config filter.gettext-no-location.clean \"msgcat --no-location -\"" $(ALL_MSGFILES): %.msg : %.po - @echo Generating catalog $@ - $(MSGFMT) --statistics --tcl -l $(basename $(notdir $<)) -d $(dir $@) $< + $(MSGFMT_GEN) + $(MSGFMT) $(MSGFMT_STATS) --tcl -l $(basename $(notdir $<)) -d $(dir $@) $< .PHONY: all install uninstall clean update-po .PHONY: FORCE -- gitgitgadget