]> git.k1024.org Git - pyxattr.git/blob - Makefile
More setup.py updates
[pyxattr.git] / Makefile
1 SPHINXOPTS    = -W
2 SPHINXBUILD   = sphinx-build
3 DOCDIR        = doc
4 DOCHTML       = $(DOCDIR)/html
5 DOCTREES      = $(DOCDIR)/doctrees
6 ALLSPHINXOPTS = -d $(DOCTREES) $(SPHINXOPTS) $(DOCDIR)
7
8 MODNAME = xattr.so
9 RSTFILES = doc/index.rst doc/module.rst NEWS README doc/conf.py
10
11 all: doc test
12
13 $(MODNAME): xattr.c
14         ./setup.py build_ext --inplace
15
16 $(DOCHTML)/index.html: $(MODNAME) $(RSTFILES)
17         $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(DOCHTML)
18         touch $@
19
20 doc: $(DOCHTML)/index.html
21
22 dist:
23         fakeroot ./setup.py sdist
24
25 test:
26         for ver in 2.4 2.5 2.6 2.7 3.0 3.1 3.2; do \
27           if type python$$ver >/dev/null; then \
28             echo Testing with python$$ver; \
29             python$$ver ./setup.py test; \
30           fi; \
31         done
32
33 clean:
34         rm -rf $(DOCHTML) $(DOCTREES)
35         rm -f $(MODNAME)
36         rm -rf build
37
38 .PHONY: doc test clean dist