tazweb annotate Makefile @ rev 125
Fix make install
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Wed Feb 27 20:07:58 2013 +0000 (2013-02-27) |
parents | 2cc313c79f49 |
children | 0940993683ef |
rev | line source |
---|---|
pankso@71 | 1 # Makefile for TazWeb |
pankso@1 | 2 # |
pankso@1 | 3 PREFIX?=/usr |
pankso@17 | 4 DOCDIR?=$(PREFIX)/share/doc |
pankso@1 | 5 DESTDIR?= |
pankso@1 | 6 |
pankso@1 | 7 PACKAGE=tazweb |
al@121 | 8 VERSION=1.6.4 |
al@123 | 9 LINGUAS?=fr pt_BR ru |
pankso@1 | 10 |
pankso@1 | 11 all: |
pankso@1 | 12 gcc src/main.c -o $(PACKAGE) \ |
pankso@1 | 13 `pkg-config --cflags --libs gtk+-2.0 webkit-1.0` |
pankso@16 | 14 @du -sh $(PACKAGE) |
pankso@1 | 15 |
al@121 | 16 # i18n |
al@121 | 17 |
al@121 | 18 pot: |
al@121 | 19 xgettext -o po/$(PACKAGE).pot -L C -k_ \ |
al@121 | 20 --package-name="TazWeb" \ |
al@121 | 21 --package-version="$(VERSION)" \ |
al@121 | 22 ./src/main.c |
al@121 | 23 |
al@121 | 24 msgmerge: |
al@121 | 25 @for l in $(LINGUAS); do \ |
al@121 | 26 echo -n "Updating $$l po file."; \ |
al@121 | 27 msgmerge -U po/$$l.po po/$(PACKAGE).pot; \ |
al@121 | 28 done; |
al@121 | 29 |
al@121 | 30 msgfmt: |
al@121 | 31 @for l in $(LINGUAS); do \ |
al@121 | 32 echo "Compiling $$l mo file..."; \ |
al@121 | 33 mkdir -p po/mo/$$l/LC_MESSAGES; \ |
al@121 | 34 msgfmt -o po/mo/$$l/LC_MESSAGES/$(PACKAGE).mo po/$$l.po; \ |
al@121 | 35 done; |
al@121 | 36 |
al@121 | 37 |
pankso@1 | 38 install: |
pankso@1 | 39 mkdir -p \ |
pankso@17 | 40 $(DESTDIR)$(DOCDIR)/$(PACKAGE) \ |
pankso@1 | 41 $(DESTDIR)$(PREFIX)/bin \ |
pankso@35 | 42 $(DESTDIR)$(PREFIX)/share/tazweb \ |
pankso@1 | 43 $(DESTDIR)$(PREFIX)/share/pixmaps \ |
pankso@1 | 44 $(DESTDIR)$(PREFIX)/share/applications |
erjo@25 | 45 install -m 0755 $(PACKAGE) $(DESTDIR)$(PREFIX)/bin |
pankso@38 | 46 cp -d doc/* $(DESTDIR)$(DOCDIR)/$(PACKAGE) |
pankso@111 | 47 install -m 0644 data/tazweb.png \ |
pankso@111 | 48 $(DESTDIR)$(PREFIX)/share/pixmaps |
pankso@1 | 49 install -m 0644 data/tazweb.desktop \ |
pankso@1 | 50 $(DESTDIR)$(PREFIX)/share/applications |
pankso@111 | 51 cp -a data/*.html $(DESTDIR)$(PREFIX)/share/tazweb |
pankso@38 | 52 install -m 0644 data/style.css \ |
pankso@36 | 53 $(DESTDIR)$(PREFIX)/share/tazweb |
al@125 | 54 mkdir -p $(DESTDIR)$(PREFIX)/share/locale |
al@121 | 55 cp -a po/mo/* $(DESTDIR)$(PREFIX)/share/locale |
pankso@1 | 56 |
pankso@1 | 57 clean: |
pankso@1 | 58 rm -f $(PACKAGE) |
al@121 | 59 rm -rf po/mo |
al@121 | 60 rm -f po/*.mo |
al@121 | 61 rm -f po/*.*~ |
al@121 | 62 |
al@121 | 63 help: |
al@121 | 64 @echo "make [ pot | msgmerge | msgfmt | install | clean ]" |