]> git.saurik.com Git - wxWidgets.git/blob - wxPython/distrib/makemo.py
properly NUL-terminate the buffer before converting it to Unicode: we may need more...
[wxWidgets.git] / wxPython / distrib / makemo.py
1 import sys, os, glob
2 from distutils.dep_util import newer
3 from distutils.spawn import spawn
4
5 poFiles = glob.glob("*.po")
6
7 for po in poFiles:
8 mo = os.path.splitext(po)[0] + '.mo'
9 if mo != 'wxstd.mo':
10 if newer(po, mo):
11 cmd = 'msgfmt --verbose -o %s %s' % (mo, po)
12 print cmd
13 spawn(cmd.split())
14 print
15 else:
16 print "%s is up to date" % mo