Preserve stack-traces when re-throwing errors
[zeroinstall.git] / Makefile
blob7a75a53100837041403e1bc43f3d1ea216284647
3 PYTHON=python
5 MO = $(shell find share/locale -name '*.po' | sort | sed -e 's/\.po/\.mo/')
6 PY = $(shell find zeroinstall -name '*.py' | sort)
7 GTKBUILDER = $(shell find zeroinstall -name '*.ui' | sort | sed -e 's/\.ui/&.h/')
8 SH = zeroinstall/zerostore/_unlzma
10 all: translations
11 $(PYTHON) setup.py build
13 translations: $(MO)
15 install: all
16 $(PYTHON) setup.py install
18 %.mo: %.po
19 msgfmt -o "$@" "$<"
21 %.ui.h: %.ui
22 intltool-extract --type=gettext/glade --update "$<"
24 share/locale/zero-install.pot: $(PY) $(GTKBUILDER) $(SH)
25 xgettext --sort-by-file --language=Python --output=$@ --keyword=N_ $(PY) $(GTKBUILDER)
26 xgettext --sort-by-file --language=Shell -j --output=$@ $(SH)
28 update-po: share/locale/zero-install.pot
29 @for po in share/locale/*/LC_MESSAGES/zero-install.po; do \
30 echo -e "Merge: $$po: \c"; \
31 msgmerge -v -U $$po share/locale/zero-install.pot; \
32 done
34 check-po:
35 @for po in share/locale/*/LC_MESSAGES/zero-install.po; do \
36 echo -e "Check: $$po: \c"; \
37 msgfmt -o /dev/null --statistics -v -c $$po; \
38 done
39 clean:
40 $(PYTHON) setup.py clean
42 .PHONY: all install update-po check-po clean