]> code.delx.au - offlineimap/blob - Makefile
Update FSF address
[offlineimap] / Makefile
1 # Copyright (C) 2002 John Goerzen
2 # <jgoerzen@complete.org>
3 #
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation; either version 2 of the License, or
7 # (at your option) any later version.
8 #
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details.
13 #
14 # You should have received a copy of the GNU General Public License
15 # along with this program; if not, write to the Free Software
16 # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17
18 VERSION=4.0.13
19 TARGZ=offlineimap_$(VERSION).tar.gz
20 SHELL=/bin/bash
21
22 clean:
23 -python2.3 setup.py clean --all
24 -rm -f `find . -name "*~"`
25 -rm -f `find . -name "*.tmp"`
26 -rm -f bin/offlineimapc
27 -rm -f `find . -name "*.pyc"`
28 -rm -f `find . -name "*.pygc"`
29 -rm -f `find . -name "*.class"`
30 -rm -f `find . -name "*.bak"`
31 -rm -f `find . -name ".cache*"`
32 -rm manpage.links
33 -rm manpage.refs
34 -find . -name auth -exec rm -vf {}/password {}/username \;
35
36 doc:
37 docbook2man offlineimap.sgml
38 docbook2man offlineimap.sgml
39 docbook2html -u offlineimap.sgml
40 mv offlineimap.html manual.html
41 man -t -l offlineimap.1 > manual.ps
42 ps2pdf manual.ps
43 groff -Tascii -man offlineimap.1 | sed $$'s/.\b//g' > manual.txt
44 -rm manpage.links manpage.refs
45
46 targz: ../$(TARGZ)
47 ../$(TARGZ):
48 if ! pwd | grep -q "/offlineimap-$(VERSION)$$"; then \
49 echo "Containing directory must be called offlineimap-$(VERSION)"; \
50 exit 1; \
51 fi; \
52 pwd && cd .. && pwd && tar -zhcv --exclude '_darcs' -f $(TARGZ) offlineimap-$(VERSION)
53
54 rpm: targz
55 cd .. && sudo rpmbuild -ta $(TARGZ)