Skip to content

Commit acb8ef2

Browse files
author
Alexander Smishlajev
committed
by default, build binary message catalogs only...
...don't update message template file or message source files unless explicitely requested; added 'help' target.
1 parent 455582f commit acb8ef2

File tree

1 file changed

+20
-6
lines changed

1 file changed

+20
-6
lines changed

locale/GNUmakefile

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Extract translatable strings from Roundup sources,
22
# update and compile all existing translations
33
#
4-
# $Id: GNUmakefile,v 1.6 2004-05-29 04:50:46 a1s Exp $
4+
# $Id: GNUmakefile,v 1.7 2004-06-13 13:06:54 a1s Exp $
55

66
# tool locations
77
XPOT ?= xpot
@@ -18,11 +18,25 @@ PO_FILES=$(wildcard *.po)
1818
MO_FILES=$(PO_FILES:.po=.mo)
1919
RUN_PYTHON=PYTHONPATH=../build/lib $(PYTHON) -O
2020

21-
.PHONY: $(TEMPLATE)
22-
23-
all: $(TEMPLATE) $(MO_FILES)
24-
25-
$(TEMPLATE):
21+
all: dist
22+
23+
help:
24+
@echo "$(MAKE) - build MO files. Run this before sdist"
25+
@echo "$(MAKE) template - update message template from sources"
26+
@echo "$(MAKE) locale.po - update message file from template"
27+
@echo "$(MAKE) locale.mo - compile individual message file"
28+
@echo "$(MAKE) help - this text"\
29+
30+
# This will rebuild all MO files without updating their corresponding PO
31+
# files first. Run before creating Roundup distribution (hence the name).
32+
# PO files should be updated by their translators only, automatic update
33+
# adds unwanted fuzzy labels.
34+
dist:
35+
for file in $(PO_FILES); do \
36+
${MSGFMT} -o `basename $$file .po`.mo $$file; \
37+
done
38+
39+
template:
2640
${XPOT} -n -o $@ $(SOURCES)
2741
${RUN_PYTHON} ../roundup/cgi/TAL/talgettext.py -u $@ \
2842
../templates/classic/html/*.html ../templates/minimal/html/*.html

0 commit comments

Comments
 (0)