From: Christian Stimming <stimming@tuhh.de>
To: "Shawn O. Pearce" <spearce@spearce.org>
Cc: Brett Schwarz <brett_schwarz@yahoo.com>,
git@vger.kernel.org, Paul Mackerras <paulus@samba.org>
Subject: Re: [PATCH 3/5] Internationalization of git-gui
Date: Sat, 21 Jul 2007 14:36:44 +0200 [thread overview]
Message-ID: <200707211436.44672.stimming@tuhh.de> (raw)
In-Reply-To: <200707211434.56622.stimming@tuhh.de>
>From cf68c8b36399d46f63e417e99c6783411213a55a Mon Sep 17 00:00:00 2001
From: Christian Stimming <chs@ckiste.goetheallee>
Date: Sat, 21 Jul 2007 14:17:07 +0200
Subject: [PATCH] Makefile rules for translation catalog generation and installation.
Signed-off-by: Christian Stimming <stimming@tuhh.de>
---
As discussed I've replaced the shell for() by the GNU make foreach. Also, there
isn't an ALL_LINGUAS variable anymore; we simply use all *.po files under po/.
Makefile | 19 ++++++++++++++++++-
1 files changed, 18 insertions(+), 1 deletions(-)
diff --git a/Makefile b/Makefile
index 1bac6fe..52975a7 100644
--- a/Makefile
+++ b/Makefile
@@ -103,6 +103,21 @@ $(patsubst %.sh,%,$(SCRIPT_SH)) : % : %.sh
$(GITGUI_BUILT_INS): git-gui
$(QUIET_BUILT_IN)rm -f $@ && ln git-gui $@
+XGETTEXT ?= xgettext
+msgsdir ?= $(libdir)/msgs
+msgsdir_SQ = $(subst ','\'',$(msgsdir))
+PO_TEMPLATE = po/git-gui.pot
+ALL_POFILES = $(wildcard po/*.po)
+ALL_MSGFILES = $(subst .po,.msg,$(ALL_POFILES))
+
+$(PO_TEMPLATE): $(SCRIPT_SH) $(ALL_LIBFILES)
+ $(XGETTEXT) -kmc -LTcl -o $@ $(SCRIPT_SH) $(ALL_LIBFILES)
+update-po:: $(PO_TEMPLATE)
+ $(foreach p, $(ALL_POFILES), echo Updating $p ; msgmerge -U $p $(PO_TEMPLATE) )
+$(ALL_MSGFILES): %.msg : %.po
+ @echo Generating catalog $@
+ msgfmt --statistics --tcl $< -l $(basename $(notdir $<)) -d $(dir $@)
+
lib/tclIndex: $(ALL_LIBFILES)
$(QUIET_INDEX)if echo \
$(foreach p,$(PRELOAD_FILES),source $p\;) \
@@ -136,7 +151,7 @@ GIT-GUI-VARS: .FORCE-GIT-GUI-VARS
echo 1>$@ "$$VARS"; \
fi
-all:: $(ALL_PROGRAMS) lib/tclIndex
+all:: $(ALL_PROGRAMS) lib/tclIndex $(ALL_MSGFILES)
install: all
$(QUIET)$(INSTALL_D0)'$(DESTDIR_SQ)$(gitexecdir_SQ)' $(INSTALL_D1)
@@ -145,6 +160,8 @@ install: all
$(QUIET)$(INSTALL_D0)'$(DESTDIR_SQ)$(libdir_SQ)' $(INSTALL_D1)
$(QUIET)$(INSTALL_R0)lib/tclIndex $(INSTALL_R1) '$(DESTDIR_SQ)$(libdir_SQ)'
$(QUIET)$(foreach p,$(ALL_LIBFILES), $(INSTALL_R0)$p $(INSTALL_R1) '$(DESTDIR_SQ)$(libdir_SQ)' &&) true
+ $(QUIET)$(INSTALL_D0)'$(DESTDIR_SQ)$(msgsdir_SQ)' $(INSTALL_D1)
+ $(QUIET)$(foreach p,$(ALL_MSGFILES), $(INSTALL_R0)$p $(INSTALL_R1) '$(DESTDIR_SQ)$(msgsdir_SQ)' &&) true
dist-version:
@mkdir -p $(TARDIR)
--
1.5.2
next prev parent reply other threads:[~2007-07-21 12:36 UTC|newest]
Thread overview: 48+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-07-19 17:33 [PATCH] Internationalization of git-gui Brett Schwarz
2007-07-20 5:04 ` Shawn O. Pearce
2007-07-20 8:56 ` Christian Stimming
2007-07-21 2:17 ` Shawn O. Pearce
2007-07-21 7:50 ` Christian Stimming
2007-07-21 8:03 ` Shawn O. Pearce
2007-07-21 12:33 ` [PATCH 1/5] " Christian Stimming
2007-07-21 12:34 ` [PATCH 2/5] " Christian Stimming
2007-07-21 12:36 ` Christian Stimming [this message]
2007-07-21 12:37 ` [PATCH 3/5] " Christian Stimming
2007-07-21 12:41 ` [PATCH 5/5] " Christian Stimming
2007-07-21 13:46 ` [PATCH 3/5] " David Kastrup
2007-07-21 16:27 ` Simon 'corecode' Schubert
2007-07-21 17:41 ` David Kastrup
2007-07-21 18:50 ` Translation process (was: [PATCH 3/5] Internationalization of git-gui) Christian Stimming
2007-07-21 19:27 ` German translations " Christian Stimming
2007-07-21 19:57 ` German translations David Kastrup
2007-07-22 13:16 ` Christian Stimming
2007-07-22 14:52 ` Edgar Toernig
2007-07-23 19:20 ` Christian Stimming
2007-07-21 20:09 ` David Kastrup
2007-07-22 7:47 ` [PATCH 3/5] Internationalization of git-gui Shawn O. Pearce
2007-07-22 8:05 ` Junio C Hamano
2007-07-22 12:16 ` Christian Stimming
2007-07-22 12:44 ` Johannes Schindelin
2007-07-22 12:57 ` Christian Stimming
2007-07-22 13:06 ` Johannes Schindelin
2007-07-22 7:45 ` [PATCH 2/5] " Shawn O. Pearce
2007-07-22 12:24 ` Christian Stimming
2007-07-21 14:22 ` [PATCH 1/5] " Johannes Schindelin
2007-07-21 19:41 ` Junio C Hamano
2007-07-21 19:50 ` Christian Stimming
2007-07-21 21:20 ` Johannes Schindelin
2007-07-21 21:28 ` Junio C Hamano
2007-07-21 21:35 ` Johannes Schindelin
2007-07-22 13:35 ` Christian Stimming
2007-07-22 14:29 ` Johannes Schindelin
2007-07-23 20:16 ` [PATCH] Add glossary that can be converted into a po file for each language Christian Stimming
2007-07-24 1:48 ` Junio C Hamano
2007-07-24 6:56 ` Junio C Hamano
2007-07-24 9:34 ` Christian Stimming
2007-07-21 21:12 ` [PATCH 1/5] Internationalization of git-gui Johannes Schindelin
2007-07-21 22:36 ` Junio C Hamano
2007-07-21 23:01 ` Johannes Schindelin
2007-07-22 7:38 ` Shawn O. Pearce
2007-07-23 19:23 ` Christian Stimming
2007-07-24 14:57 ` Shawn O. Pearce
2007-07-20 9:03 ` [PATCH] " Christian Stimming
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=200707211436.44672.stimming@tuhh.de \
--to=stimming@tuhh.de \
--cc=brett_schwarz@yahoo.com \
--cc=git@vger.kernel.org \
--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).