diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2007-08-12 10:02:01 +0200 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2007-08-12 10:02:01 +0200 |
commit | b12403458e20fbd3d8201f9c14a5bd8dffb854ee (patch) | |
tree | 04f3d668fcf0179feb7f49f452c8131f00ef40b1 /i18n-to-gettext.pl | |
parent | 84faea7f0d74d596189d6f7073fa2a976a892b34 (diff) | |
download | vdr-b12403458e20fbd3d8201f9c14a5bd8dffb854ee.tar.gz vdr-b12403458e20fbd3d8201f9c14a5bd8dffb854ee.tar.bz2 |
Now writing modified Makefile to Makefile.new
Diffstat (limited to 'i18n-to-gettext.pl')
-rwxr-xr-x | i18n-to-gettext.pl | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/i18n-to-gettext.pl b/i18n-to-gettext.pl index 385a8525..79b2aab7 100755 --- a/i18n-to-gettext.pl +++ b/i18n-to-gettext.pl @@ -10,7 +10,7 @@ # See the main source file 'vdr.c' for copyright information and # how to reach the author. # -# $Id: i18n-to-gettext.pl 1.1 2007/08/11 10:36:33 kls Exp $ +# $Id: i18n-to-gettext.pl 1.2 2007/08/12 10:02:01 kls Exp $ # How to convert an actual plugin: # @@ -49,7 +49,12 @@ # - Your Makefile will be automatically adjusted to allow for # building the *.mo files necessary for supporting gettext(). # Please check carefully whether the automatic adjustments have -# succeeded, though. +# succeeded, though. The modified Makefile will be written to +# Makefile.new, so you can call this script any numer of times +# in case you need to do some fine tuning of your texts (especially +# adding some trNOOP() in case the script reports "missing phrases". +# Once you're done converting your plugin source to using gettext, +# rename Makefile.new to Makefile. # # - You may want to remove the old internationalized texts from your # source. Usually this means removing the files i18n.[hc], stripping @@ -308,9 +313,8 @@ i18n: $(I18Nmo) }; -`mv Makefile Makefile.old`; -open(OLD, "Makefile.old") || die "Makefile.old: $!"; -open(NEW, ">Makefile") || die "Makefile: $!"; +open(OLD, "Makefile") || die "Makefile: $!"; +open(NEW, ">Makefile.new") || die "Makefile.new: $!"; while (<OLD>) { chomp; if (/Targets:/) { |