Re: msgmft segfaulting on tiger

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



"Shawn O. Pearce" <spearce@xxxxxxxxxxx> writes:

> Just to revive a nearly dead thead...  I have a workaround now in
> git-gui maint that looks for this case and falls into our po2msg
> script when msgfmt doesn't see --tcl.
>
> I also set Paul Mackerras a patch for gitk, so it can do the
> same thing.  Maybe Git 1.5.4.4 will include both patches.

I looked at what you have in your Makefile.  

It makes me wonder, however, if it makes more sense to squash the two
invocations of msgfmt you make into one, like the attached patch.

The point is that msgfmt you guys want to use _must_ understand --tcl,
and a msgfmt new enough to be usable would exit with 0 on the above
command line.

-- >8 --
gitk i18n: Fall back to po2msg.sh if msgfmt --tcl fails

Some platforms may have a msgfmt that doesn't understand --tcl.  Mac OS X
Tiger is an example.

Falling back to po2msg.sh on such systems is a reasonable behavior.

Signed-off-by: Junio C Hamano <gitster@xxxxxxxxx>
---
 Makefile |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/Makefile b/Makefile
index ae2b80b..c72e7f7 100644
--- a/Makefile
+++ b/Makefile
@@ -22,6 +22,9 @@ ifdef NO_MSGFMT
 	MSGFMT ?= $(TCL_PATH) po/po2msg.sh
 else
 	MSGFMT ?= msgfmt
+	ifneq ($(shell $(MSGFMT) --tcl -l C -d . /dev/null 2>/dev/null; echo $?),0)
+		MSGFMT = $(TCL_PATH) po/po2msg.sh 
+	endif
 endif
 
 PO_TEMPLATE = po/gitk.pot

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux