git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: "Shawn O. Pearce" <spearce@spearce.org>,
	Paul Mackerras <paulus@samba.org>
Cc: "Gabriel Saldaña" <gsaldana@gmail.com>,
	"Johannes Schindelin" <Johannes.Schindelin@gmx.de>,
	"Martin Langhoff" <martin.langhoff@gmail.com>,
	"Git Mailing List" <git@vger.kernel.org>
Subject: Re: msgmft segfaulting on tiger
Date: Thu, 06 Mar 2008 00:40:56 -0800	[thread overview]
Message-ID: <7v63w0gs87.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <20080305071915.GI8410@spearce.org> (Shawn O. Pearce's message of "Wed, 5 Mar 2008 02:19:15 -0500")

"Shawn O. Pearce" <spearce@spearce.org> 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@pobox.com>
---
 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


  reply	other threads:[~2008-03-06  8:42 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-21 23:53 msgmft segfaulting on tiger Martin Langhoff
2008-02-21 23:59 ` Martin Langhoff
2008-02-22  6:58   ` Shawn O. Pearce
2008-02-22 17:57     ` Martin Langhoff
2008-02-27 18:18       ` Gabriel Saldaña
2008-02-27 18:26         ` Johannes Schindelin
2008-02-27 18:42           ` Gabriel Saldaña
2008-02-27 22:04             ` Johannes Schindelin
2008-02-27 22:14               ` Junio C Hamano
2008-02-28  0:32                 ` Shawn O. Pearce
2008-03-04  7:02                   ` msgmft segfaulting on ubuntu gutsy (clean) Gabriel Saldaña
2008-03-04  7:07                     ` Shawn O. Pearce
2008-02-28 18:40                 ` msgmft segfaulting on tiger Gabriel Saldaña
2008-03-05  7:19                   ` Shawn O. Pearce
2008-03-06  8:40                     ` Junio C Hamano [this message]
2008-03-12  5:29                       ` [PATCH] Simplify MSGFMT setting in Makefile Junio C Hamano
2008-03-12  5:51                         ` Shawn O. Pearce
2008-03-12 10:19                         ` Charles Bailey
2008-03-14  4:44                         ` Paul Mackerras
2008-03-14  4:50                           ` Junio C Hamano
2008-03-14 13:07                           ` Andreas Ericsson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7v63w0gs87.fsf@gitster.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=gsaldana@gmail.com \
    --cc=martin.langhoff@gmail.com \
    --cc=paulus@samba.org \
    --cc=spearce@spearce.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).