summaryrefslogtreecommitdiffstats
path: root/perl-install/share/po/Makefile
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2001-07-02 14:00:36 +0000
committerPascal Rigaux <pixel@mandriva.com>2001-07-02 14:00:36 +0000
commit723df32220af3a6972d7353579633d2faccc5d9a (patch)
tree1f4d3e470c362e85af46a4fa81af53e71e446419 /perl-install/share/po/Makefile
parent1d4648346c49938f9e92fce4c6d5dbe9bb6df77d (diff)
downloaddrakx-backup-do-not-use-723df32220af3a6972d7353579633d2faccc5d9a.tar
drakx-backup-do-not-use-723df32220af3a6972d7353579633d2faccc5d9a.tar.gz
drakx-backup-do-not-use-723df32220af3a6972d7353579633d2faccc5d9a.tar.bz2
drakx-backup-do-not-use-723df32220af3a6972d7353579633d2faccc5d9a.tar.xz
drakx-backup-do-not-use-723df32220af3a6972d7353579633d2faccc5d9a.zip
- fix to add some missing messages
- add more verif
Diffstat (limited to 'perl-install/share/po/Makefile')
-rw-r--r--perl-install/share/po/Makefile13
1 files changed, 11 insertions, 2 deletions
diff --git a/perl-install/share/po/Makefile b/perl-install/share/po/Makefile
index b308e9dde..70036dc4f 100644
--- a/perl-install/share/po/Makefile
+++ b/perl-install/share/po/Makefile
@@ -3,11 +3,12 @@ include ../../Makefile.config
PMSFILES = $(wildcard $(PMS:%=../../%))
PMSCFILES = $(PMSFILES:%=%_.c)
POFILES = $(shell ls *.po)
+PERL2C =
all: $(POFILES)
clean:
- rm -f empty.po messages $(POFILES:%=%t) $(PMSCFILES)
+ rm -f empty.po tmp.* messages tmp.pot $(POFILES:%=%t) $(PMSCFILES)
verif:
perl -ne '/^\s*#/ or $$i += my @l = /\b__?\(/g; END { print "$$i\n" }' $(PMSFILES)
@@ -24,7 +25,15 @@ DrakX.pot: $(PMSFILES)
rm $(PMSCFILES)
perl i18n_compssUsers 2>/dev/null >> $@
+verif2:
+ perl -I ../.. -Mcommon -e 'foreach (qw($(PMSFILES))) { printf "package foo%d;\n", ++$$i; print common::cat_($$_) }' | perl -ne 'print if !/use (diagnostics|vars|strict)/' | OUTFILE=tmp.pm perl -I. -I../.. -Mb_dump_strings >/dev/null 2>/dev/null
+ perl -pe 's|$$|\\n\\|' tmp.pm > tmp.pm_.c
+ xgettext --keyword=_ -o tmp.po tmp.pm_.c
+ msgmerge DrakX.pot tmp.po > tmp.pot
+ grep "^msgid" tmp.pot | sort > tmp.pot.light
+ grep "^msgid" DrakX.pot | sort | diff - tmp.pot.light | grep "^>"
+
$(PMSCFILES): %_.c: %
- perl -pe 's|^(__?\()| $$1|; s|//|/""/|g; s,(^|[^\$$])#([^+].*),\1/*\2*\/,; s|$$|\\n\\|' $< > $@
+ perl -pe 's|^(__?\()| $$1|; s,\Qs/#.*//,,; s|//|/""/|g; s,(^|[^\$$])#([^+].*),\1/*\2*/,; s|$$|\\n\\|' $< > $@
# for i in *.po; do echo -n "$i "; msgfmt -v $i 2>&1; done | perl -e 'print map { $_->[0] } sort { $a->[1] <=> $b->[1] } map { [ $_, (split)[1] ] } <>'