blob: 3e8e1a72b3a9be5ad408ab7257f5e312da16777d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
PMSFILES = $(shell find .. -name "*.pm" | grep -v "^../po" | grep -v "^../c/")
PMSCFILES = $(PMSFILES:%=%_.c)
POFILES = $(shell ls *.po)
all: $(POFILES)
clean:
rm -f empty.po $(POFILES:%=%t) $(PMSCFILES)
verif:
perl -ne '/^\s*#/ or $$i += my @l = /\b__?\(/g; END { print "$$i\n" }' $(PMSFILES)
perl -ne '$$i += my @l = /\.c:/g; END { print "$$i\n" }' panoramix.pot
$(POFILES): panoramix.pot
cp -f $@ $@t
msgmerge $@t $< > $@
rm $@t
panoramix.pot: $(PMSFILES)
$(MAKE) $(PMSCFILES);
xgettext -F -n --keyword=_ --keyword=__ -o panoramix.pot $(PMSCFILES)
rm $(PMSCFILES)
$(PMSCFILES): %_.c: %
perl -pe 's|^(__?\()| $$1|; s|#(.*)|/*\1*\/|; s|$$|\\n\\|' $< > $@
|