l10n: Updated French (fr) translation to 100%
[gpodder.git] / data / po / Makefile
blob62c4dd6e2f5485ff4b075b65587e0b222fce6b15
2 # gPodder - A media aggregator and podcast client
3 # Copyright (c) 2005-2010 Thomas Perl and the gPodder Team
5 # gPodder is free software; you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; either version 3 of the License, or
8 # (at your option) any later version.
10 # gPodder is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program. If not, see <http://www.gnu.org/licenses/>.
20 PO_FILES=$(wildcard *.po)
21 POT_FILE=../messages.pot
23 # Check for $LINGUAS presence.
24 ifeq ($(origin LINGUAS), undefined)
25 PO_INSTALL=$(PO_FILES)
26 else
27 PO_INSTALL=$(addsuffix .po,$(filter $(subst .po,,$(PO_FILES)),$(LINGUAS)))
28 endif
30 MO_FILES=$(addsuffix /LC_MESSAGES/gpodder.mo,$(addprefix ../locale/,$(subst .po,,$(PO_INSTALL))))
32 all: $(PO_INSTALL) $(MO_FILES)
34 %.po: $(POT_FILE)
35 @echo "Merging $(notdir $<) -> $@"
36 @msgmerge --silent $@ $< --output-file=$@
38 %.mo: $(PO_INSTALL)
39 @echo "Compiling $(subst /LC_MESSAGES/gpodder.mo,.po,$(subst ../locale/,,$@)) -> $(notdir $@)"
40 @mkdir -p $(@D)
41 @msgfmt $(subst /LC_MESSAGES/gpodder.mo,.po,$(subst ../locale/,,$@)) -o $@
43 clean:
44 rm -rf ../locale *~ *.mo
46 statistics:
47 @for file in *.po; do echo -n "$$file (`cat $$file | grep Revision-Date | cut -d' ' -f2`): "; msgfmt --statistics $$file 2>&1; done
49 validate:
50 ./validate.sh
52 .PHONY: all clean statistics validate