]> git.saurik.com Git - wxWidgets.git/commitdiff
Script for building mo locale files.
authorKevin Ollivier <kevino@theolliviers.com>
Fri, 16 Dec 2005 17:37:05 +0000 (17:37 +0000)
committerKevin Ollivier <kevino@theolliviers.com>
Fri, 16 Dec 2005 17:37:05 +0000 (17:37 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@36410 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

wxPython/distrib/makemo.py [new file with mode: 0644]

diff --git a/wxPython/distrib/makemo.py b/wxPython/distrib/makemo.py
new file mode 100644 (file)
index 0000000..cbdc1e2
--- /dev/null
@@ -0,0 +1,16 @@
+import sys, os, glob
+from distutils.dep_util import newer
+from distutils.spawn import spawn
+
+poFiles = glob.glob("*.po")
+
+for po in poFiles:
+   mo = os.path.splitext(po)[0] + '.mo'
+   if mo != 'wxstd.mo':
+       if newer(po, mo):
+           cmd = 'msgfmt --verbose -o %s %s' % (mo, po)
+           print cmd
+           spawn(cmd.split())
+           print
+       else:
+           print "%s is up to date" % mo