Subject: Re: What's not in 'master', and likely not to be until 1.5.4

From: "Shawn O. Pearce" <[email-masked]>
Date: Tue, 22 Jan 2008 23:44:28 -0500

Johannes Schindelin <[email-masked]> wrote:
> Note: There might be yet a better way.  Instead of trying each and every 
> time, we could detect the presence of msgfmt with something like this:
> 
> +ifeq $(shell msgfmt2 2>/dev/null >/dev/null; echo $?) = 127
> +	MSGFMT = $(TCL_PATH) po/po2msg.sh
> +endif

I like it.  I'm applying this diff (which I tested) to git-gui:

diff --git a/Makefile b/Makefile
index 1baf4b0..5f1023e 100644
--- a/Makefile
+++ b/Makefile
@@ -198,6 +198,9 @@ ifdef NO_MSGFMT
 	MSGFMT ?= $(TCL_PATH) po/po2msg.sh
 else
 	MSGFMT ?= msgfmt
+	ifeq ($(shell $(MSGFMT) >/dev/null 2>&1 || echo $$?),127)
+		MSGFMT := $(TCL_PATH) po/po2msg.sh
+	endif
 endif
 
 msgsdir     = $(gg_libdir)/msgs

-- 
Shawn.