slitaz-pizza annotate Makefile @ rev 91

pizza.cgi: notes should not be executable
author Pascal Bellard <pascal.bellard@slitaz.org>
date Mon Jan 28 09:30:48 2013 +0100 (2013-01-28)
parents 165c6a5478c2
children 5d7a43f409a3
rev   line source
pankso@5 1 # Makefile for SliTaz Pizza.
pankso@5 2 #
pankso@5 3
pankso@5 4 PACKAGE="pizza"
pankso@5 5 PREFIX?=/usr
pankso@5 6 DESTDIR?=
al@59 7 LINGUAS?=fr sv
pankso@5 8
pankso@5 9 all:
pankso@5 10
pankso@5 11 # i18n
pankso@5 12
pankso@5 13 pot:
pankso@5 14 xgettext -o po/pizza.pot -L Shell --package-name="SliTaz Pizza" \
pankso@23 15 ./web/pizza.cgi ./web/pkgs.cgi
pankso@5 16
pankso@5 17 msgmerge:
pankso@5 18 @for l in $(LINGUAS); do \
pankso@5 19 echo -n "Updating $$l po file."; \
pankso@5 20 msgmerge -U po/$$l.po po/$(PACKAGE).pot; \
pankso@5 21 done;
pankso@5 22
pankso@5 23 msgfmt:
pankso@5 24 @for l in $(LINGUAS); do \
pankso@5 25 echo "Compiling $$l mo file..."; \
pankso@5 26 mkdir -p po/mo/$$l/LC_MESSAGES; \
pankso@5 27 msgfmt -o po/mo/$$l/LC_MESSAGES/pizza.mo po/$$l.po; \
pankso@5 28 done;
pankso@5 29
pankso@5 30 # Installation
pankso@5 31
pankso@5 32 install: msgfmt
erjo@72 33 install -m 0755 -d $(DESTDIR)/etc/slitaz
erjo@72 34 install -m 0755 -d $(DESTDIR)$(PREFIX)/bin
erjo@72 35 install -m 0755 -d $(DESTDIR)$(PREFIX)/share/pizza/public
erjo@72 36 install -m 0755 -d $(DESTDIR)$(PREFIX)/share/pizza/web
erjo@72 37 install -m 0755 -d $(DESTDIR)$(PREFIX)/share/pizza/web/images
erjo@72 38 install -m 0755 -d $(DESTDIR)$(PREFIX)/share/pizza/web/lib
erjo@72 39 install -m 0755 -d $(DESTDIR)$(PREFIX)/share/doc/pizza
pankso@5 40 install -m 0755 pizza $(DESTDIR)$(PREFIX)/bin
pankso@5 41 install -m 0755 pizza-bot $(DESTDIR)$(PREFIX)/share/pizza
erjo@72 42 install -m 0755 public/index.cgi $(DESTDIR)$(PREFIX)/share/pizza/public
pankso@5 43 install -m 0755 data/* $(DESTDIR)$(PREFIX)/share/pizza
pankso@5 44 install -m 0644 pizza.conf $(DESTDIR)/etc/slitaz
pankso@5 45 install -m 0644 README $(DESTDIR)$(PREFIX)/share/doc/pizza
pankso@40 46 cp -a doc/* $(DESTDIR)$(PREFIX)/share/doc/pizza
erjo@72 47 cp -a po/mo $(DESTDIR)$(PREFIX)/share/locale
pankso@5 48 cp -a web $(DESTDIR)$(PREFIX)/share/pizza
pankso@5 49 chown -R root.root $(DESTDIR)$(PREFIX)/share/pizza
erjo@72 50 chmod 755 $(DESTDIR)$(PREFIX)/share/pizza/web/*.cgi
pankso@5 51
pankso@5 52 uninstall:
pankso@5 53 rm -rf \
pankso@5 54 $(DESTDIR)$(PREFIX)/bin/pizza \
pankso@5 55 $(DESTDIR)/etc/slitaz/pizza.conf \
pankso@5 56 $(DESTDIR)$(PREFIX)/share/pizza \
pankso@5 57 $(DESTDIR)$(PREFIX)/share/doc/pizza
pankso@5 58
pankso@5 59 clean:
pankso@5 60 rm -rf po/*~
pankso@14 61 rm -rf po/mo
pankso@14 62