Commit

6911df05387559350cf024d3e77d8a855f6213a3

gitk: make "make -s" silent

The catalog rule runs msgfmt with --statistics, whose output goes to
stderr and so survives "make -s", and the rule also echoes "Generating
catalog". The Gitk Makefile guards its quiet helpers on V alone, so a
silent build still prints these and the GEN line.

The statistics are not needed, as in 2f12b31b746c (Makefile: don't
invoke msgfmt with --statistics, 2021-12-17). Drop them, suppress the
quiet helpers when "s" is among the make flags, and give the catalog
rule a quiet prefix so a quiet build stays quiet.

Signed-off-by: Harald Nordgren <haraldnordgren@gmail.com>
Signed-off-by: Johannes Sixt <j6t@kdbg.org>

Harald Nordgren <haraldnordgren@gmail.com> · 2026-06-21 14:56 UTC · committed by Johannes Sixt

Browse files
1 file changed, +4 −2
modified Makefile
@@ -43,9 +43,12 @@ PO_TEMPLATE = po/gitk.pot
43 43 ALL_POFILES = $(wildcard po/*.po)
44 44 ALL_MSGFILES = $(subst .po,.msg,$(ALL_POFILES))
45 45
46 + ifneq ($(findstring s,$(firstword -$(MAKEFLAGS))),s)
46 47 ifndef V
47 48 QUIET = @
48 49 QUIET_GEN = $(QUIET)echo ' ' GEN $@ &&
50 + QUIET_MSGFMT = $(QUIET)echo ' ' MSGFMT $@ &&
51 + endif
49 52 endif
50 53
51 54 all:: gitk-wish $(ALL_MSGFILES)
@@ -75,8 +78,7 @@ update-po:: $(PO_TEMPLATE)
75 78 echo; \
76 79 echo " git config filter.gettext-no-location.clean \"msgcat --no-location -\""
77 80 $(ALL_MSGFILES): %.msg : %.po
78 - @echo Generating catalog $@
79 - $(MSGFMT) --statistics --tcl -l $(basename $(notdir $<)) -d $(dir $@) $<
81 + $(QUIET_MSGFMT)$(MSGFMT) --tcl -l $(basename $(notdir $<)) -d $(dir $@) $<
80 82
81 83 .PHONY: all install uninstall clean update-po
82 84 .PHONY: FORCE