2011-01-15 16:48:30 +01:00
|
|
|
# This program is free software under the terms of the GNU General Public
|
|
|
|
# License. See the COPYING file which must come with this package.
|
|
|
|
|
|
|
|
SOURCES = $(wildcard *.rst)
|
|
|
|
HTML_TARGETS = $(patsubst %.rst,%.html,$(SOURCES))
|
|
|
|
|
|
|
|
RM = rm
|
2011-03-07 22:23:21 +01:00
|
|
|
RST2HTML=`type rst2html >/dev/null 2>&1 && echo rst2html || echo rst2html.py`
|
|
|
|
RST2MAN=`type rst2man >/dev/null 2>&1 && echo rst2man || echo rst2man.py`
|
2011-04-27 10:37:15 +02:00
|
|
|
SPHINXBUILD = sphinx-build
|
2011-01-15 16:48:30 +01:00
|
|
|
|
2011-04-27 10:37:15 +02:00
|
|
|
all: html dev-doc
|
2011-01-15 16:48:30 +01:00
|
|
|
|
|
|
|
html: $(HTML_TARGETS)
|
|
|
|
|
|
|
|
$(HTML_TARGETS): %.html : %.rst
|
2011-01-27 19:50:24 +01:00
|
|
|
$(RST2HTML) $? $@
|
2011-01-15 16:48:30 +01:00
|
|
|
|
|
|
|
man: offlineimap.1
|
|
|
|
|
|
|
|
offlineimap.1: MANUAL.rst
|
2011-01-27 19:50:24 +01:00
|
|
|
$(RST2MAN) MANUAL.rst offlineimap.1
|
2011-01-15 16:48:30 +01:00
|
|
|
cp -f offlineimap.1 ..
|
|
|
|
|
2011-04-27 10:37:15 +02:00
|
|
|
dev-doc:
|
|
|
|
$(SPHINXBUILD) -b html -d dev-doc/doctrees dev-doc-src dev-doc/html
|
|
|
|
|
2011-01-15 16:48:30 +01:00
|
|
|
clean:
|
|
|
|
$(RM) -f $(HTML_TARGETS)
|
|
|
|
$(RM) -f offlineimap.1 ../offlineimap.1
|
2011-04-27 10:37:15 +02:00
|
|
|
$(RM) -rf dev-doc/*
|
|
|
|
|
|
|
|
.PHONY: dev-doc
|