~wattazoum/python-schedule/devel

« back to all changes in this revision

Viewing changes to Makefile

  • Committer: Oumar Aziz OUATTARA (alias wattazoum)
  • Date: 2007-10-20 10:50:15 UTC
  • Revision ID: wattazoum@gmail.com-20071020105015-ptv7f2bx7ujsg1zu
Packaging done

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
ifndef DESTDIR
2
 
        DESTDIR = /usr/local
3
 
endif 
4
 
 
5
 
PO = `ls po/*.po | sed s/"po\/"// | sed s/".po"//`
6
 
PREFIX = /usr/local
7
 
SUPPORT = $(DESTDIR)/share/python-schedule/
8
 
DOC = $(DESTDIR)/share/doc/python-schedule/
9
 
# classes dir
10
 
SUBCLSDIR = lib/python2.5/site-packages/schedule
11
 
CLSDIR = $(DESTDIR)/$(SUBCLSDIR)
12
 
 
13
 
all:
14
 
 
15
 
default:
16
 
 
17
 
install: po-data install-po 
18
 
        install -d $(CLSDIR) $(DOC)
19
 
        cp -rf src/schedule/* $(CLSDIR)
20
 
        
21
 
uninstall:
22
 
        rm -rf $(DOC)
23
 
        rm -rf $(CLSDIR)
24
 
        find $(DESTDIR)/share/locale/ -name python-schedule.mo -exec rm -rf '{}' \;
25
 
 
26
 
clean:
27
 
        for lang in $(PO); do rm -rf po/$$lang ; done
28
 
        find ./ -name *.pyc -exec rm -f '{}' \;
29
 
        -rm -f po/*~
30
 
        -rm -f *~
31
 
 
32
 
install-po:
33
 
        for lang in $(PO); do install -d $(DESTDIR)/share/locale/$$lang/LC_MESSAGES/ ; done
34
 
        for lang in $(PO); do install -m 644 po/$$lang/LC_MESSAGES/* $(DESTDIR)/share/locale/$$lang/LC_MESSAGES/ ; done
35
 
 
36
 
po-dir:
37
 
        for lang in $(PO); do mkdir -p po/$$lang/LC_MESSAGES/ ; done
38
 
 
39
 
po-data: po-dir
40
 
        for lang in $(PO); do msgfmt po/$$lang.po -o po/$$lang/LC_MESSAGES/python-schedule.mo ; done
41
 
 
42
 
po-gen:
43
 
        xgettext -k_ -kN_ -o po/messages.pot -L Python src/schedule/*.py
44
 
        for lang in $(PO); do msgmerge -U po/$$lang.po po/messages.pot; done