Maemo 5: Settings dialog (no close button, has parent)
[panucci.git] / makefile
blob18f14ce1e9c92da4422759ce0b7e5fa11bc994ac
2 # This file is part of Panucci.
3 # Copyright (c) 2008-2011 The Panucci Project
5 # Panucci 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 # Panucci 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 Panucci. If not, see <http://www.gnu.org/licenses/>.
19 PREFIX ?= /usr
20 DESTDIR ?= /
22 MESSAGESPOT = data/messages.pot
24 TRANSLATION_SOURCES=$(wildcard src/panucci/*.py) $(wildcard src/panucci/backends/*.py)
26 PYTHON ?= python
28 data/panucci.service: data/panucci.service.in
29 sed 's|@INSTALL_PREFIX@|'/$(PREFIX)'|g' < data/panucci.service.in > data/panucci.service
32 install: mo data/panucci.service
33 $(PYTHON) setup.py install --root=$(DESTDIR) --prefix=$(PREFIX)
35 test:
36 PYTHONPATH=src/ $(PYTHON) bin/panucci --debug
38 po:
39 xgettext -k_ -kN_ --from-code utf-8 -Lpython -o $(MESSAGESPOT) $(TRANSLATION_SOURCES)
40 for langfile in data/po/*.po; do msgmerge -q -U $${langfile} $(MESSAGESPOT); done
42 mo:
43 for langfile in data/po/*.po; do \
44 mo_dir="data/locale/`basename $${langfile} .po`/LC_MESSAGES/"; \
45 mkdir -p $${mo_dir}; \
46 msgfmt $${langfile} -o $${mo_dir}/panucci.mo; \
47 done
49 clean:
50 find src/ -name '*.pyc' -exec rm '{}' \;
51 find src/ -name '*.pyo' -exec rm '{}' \;
52 rm -rf build data/locale
53 rm -f data/panucci.service data/po/*~
55 distclean: clean
56 rm -rf dist
58 .PHONY: install test po mo clean distclean