tazweb annotate Makefile @ rev 121
Add i18n to src, Makefile & README; BSD license from Wikipedia; add comment to .desktop file; add Russian translation to .po and .desktop file
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Wed Feb 27 18:15:40 2013 +0000 (2013-02-27) |
parents | 4742464dd376 |
children | 2cc313c79f49 |
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@121 | 9 LINGUAS?=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@121 | 54 cp -a po/mo/* $(DESTDIR)$(PREFIX)/share/locale |
pankso@1 | 55 |
pankso@1 | 56 clean: |
pankso@1 | 57 rm -f $(PACKAGE) |
al@121 | 58 rm -rf po/mo |
al@121 | 59 rm -f po/*.mo |
al@121 | 60 rm -f po/*.*~ |
al@121 | 61 |
al@121 | 62 help: |
al@121 | 63 @echo "make [ pot | msgmerge | msgfmt | install | clean ]" |