tazbug view Makefile @ rev 154

fix GETfiltered for "
author Pascal Bellard <pascal.bellard@slitaz.org>
date Wed Jan 09 23:47:06 2019 +0100 (2019-01-09)
parents 4dab1a5b9cb6
children 435cc2b750a5
line source
1 # Makefile for SliTaz Bugs.
2 #
4 PACKAGE="tazbug"
5 PREFIX?=/usr
6 DESTDIR?=
7 WEB?=/var/www
8 VAR?=/var/lib/slitaz
9 LINGUAS?=de el es fr ja pl pt_BR ru vi zh_CN
11 all: msgfmt
13 # i18n
15 pot:
16 xgettext -o po/tazbug.pot -L Shell --package-name="SliTaz Bugs" \
17 ./web/bugs.cgi
18 xgettext -o po/cli/tazbug-cli.pot -L Shell --package-name="Tazbug cli" \
19 ./tazbug
21 msgmerge:
22 @for l in $(LINGUAS); do \
23 echo -n "Updating $$l po file."; \
24 msgmerge -U po/$$l.po po/$(PACKAGE).pot; \
25 done;
27 msgfmt:
28 @for l in $(LINGUAS); do \
29 echo "Compiling $$l mo file..."; \
30 mkdir -p po/mo/$$l/LC_MESSAGES; \
31 msgfmt -o po/mo/$$l/LC_MESSAGES/$(PACKAGE).mo po/$$l.po; \
32 done;
34 # Client install only. Server part is not packaged
36 install:
37 install -m 0777 -d $(DESTDIR)$(PREFIX)/bin
38 install -m 0777 -d $(DESTDIR)$(PREFIX)/share/applications
39 install -m 0755 tazbug $(DESTDIR)$(PREFIX)/bin
40 install -m 0644 data/tazbug.desktop \
41 $(DESTDIR)$(PREFIX)/share/applications
43 # On SliTaz vhost: make install-web WEB=/home/slitaz/www
45 install-web:
46 install -m 0700 -d $(DESTDIR)$(VAR)/people
47 install -m 0700 -d $(DESTDIR)$(VAR)/auth
48 install -m 0777 -d $(DESTDIR)$(WEB)/bugs
49 # authfile
50 touch $(DESTDIR)$(VAR)/auth/people
51 chmod 0600 $(DESTDIR)$(VAR)/auth/people
52 # admin users
53 touch $(DESTDIR)$(VAR)/auth/admin
54 chmod 0600 $(DESTDIR)$(VAR)/auth/people
55 cp -a web/* $(DESTDIR)$(WEB)/bugs
56 cp README $(DESTDIR)$(WEB)/bugs
57 chown -R www.www $(DESTDIR)$(VAR)/*
58 chown -R www.www $(DESTDIR)$(WEB)/bugs/bug
59 # i18n
60 install -m 0755 -d $(DESTDIR)$(PREFIX)/share/locale
61 cp -a po/mo/* $(DESTDIR)$(PREFIX)/share/locale
63 # Uninstall client
65 uninstall:
66 rm -f $(DESTDIR)$(PREFIX)/bin/tazbug*
67 rm -f $(DESTDIR)$(PREFIX)/share/applications/tazbug*
68 rm -f $(DESTDIR)$(PREFIX)/etc/slitaz/tazbug.conf
70 # Clean source
72 clean:
73 rm -rf po/mo
74 rm -f po/*~