Skip to content

Commit

Permalink
setup.py: Don't require the msgfmt program to be present unless neces…
Browse files Browse the repository at this point in the history
…sary.
  • Loading branch information
stump committed Dec 30, 2012
1 parent 5838210 commit 4ffb4db
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/setup.py
Expand Up @@ -376,7 +376,6 @@ def run(self, *args, **kw):


# Convert .po files into .mo files.
msgfmt_cmd = find_command('msgfmt')
class msgfmt(Command):
user_options = []
description = 'convert .po files in data/po into .mo files in data/translations'
Expand All @@ -388,6 +387,7 @@ def finalize_options(self):
pass

def run(self):
msgfmt_cmd = find_command('msgfmt')
for pofile in glob.glob(os.path.join('..', 'data', 'po', '*.po')):
mofile = os.path.join('..', 'data', 'translations', os.path.basename(pofile)[:-3]+'.mo')
if newer(pofile, mofile):
Expand Down

0 comments on commit 4ffb4db

Please sign in to comment.