cookutils diff Makefile @ rev 624

Fix doc desktop file category
author Christophe Lincoln <pankso@slitaz.org>
date Sun Dec 22 13:06:10 2013 +0100 (2013-12-22)
parents 50cd87593dae
children dab2c8b677a9
line diff
     1.1 --- a/Makefile	Sat May 19 05:17:29 2012 +0200
     1.2 +++ b/Makefile	Sun Dec 22 13:06:10 2013 +0100
     1.3 @@ -3,6 +3,8 @@
     1.4  
     1.5  PREFIX?=/usr
     1.6  DESTDIR?=
     1.7 +LINGUAS?=ru
     1.8 +VERSION:=$(shell grep ^VERSION cook | cut -d'=' -f2)
     1.9  
    1.10  all:
    1.11  
    1.12 @@ -65,3 +67,40 @@
    1.13  		$(DESTDIR)$(PREFIX)/bin/cross \
    1.14  		$(DESTDIR)/etc/slitaz/cross.conf \
    1.15  		$(DESTDIR)$(PREFIX)/share/doc/cookutils/cross.txt
    1.16 +
    1.17 +# i18n
    1.18 +
    1.19 +pot:
    1.20 +	xgettext -o po/cook.pot -k_ -k_n -L Shell -cL10n \
    1.21 +		--copyright-holder="SliTaz Association" \
    1.22 +		--package-name="Cook" \
    1.23 +		--package-version="$(VERSION)" \
    1.24 +		./cook
    1.25 +
    1.26 +msgmerge:
    1.27 +	@for l in $(LINGUAS); do \
    1.28 +		echo -n "Updating $$l po file."; \
    1.29 +		msgmerge -U po/$$l.po po/cook.pot; \
    1.30 +	done;
    1.31 +
    1.32 +msgfmt:
    1.33 +	@for l in $(LINGUAS); do \
    1.34 +		echo "Compiling $$l mo file..."; \
    1.35 +		mkdir -p po/mo/$$l/LC_MESSAGES; \
    1.36 +		msgfmt -o po/mo/$$l/LC_MESSAGES/cook.mo po/$$l.po; \
    1.37 +	done;
    1.38 +
    1.39 +# Clean source
    1.40 +
    1.41 +clean:
    1.42 +	rm -rf po/mo
    1.43 +	rm -f po/*.mo
    1.44 +	rm -f po/*.*~
    1.45 +
    1.46 +help:
    1.47 +	@echo "make"
    1.48 +	@echo "    install         | uninstall         - all"
    1.49 +	@echo "    install-cook    | uninstall-cook    - cook"
    1.50 +	@echo "    install-libcook | uninstall-libcook - libcook"
    1.51 +	@echo "    install-cross   | uninstall-cross   - cross"
    1.52 +	@echo "    pot | msgmerge | msgfmt | clean     - i18n"