Delay checking size until it's actually used.
[jelmer/dulwich-libgit2.git] / Makefile
index 4a1a544075512a749af95f463b1faedfff4b5cd3..ec229b776eaf39517d47a8dabe2d64b7e8f49d53 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,17 +1,34 @@
 PYTHON = python
 SETUP = $(PYTHON) setup.py
-TRIAL = trial
+PYDOCTOR ?= pydoctor
+TESTRUNNER = $(shell which nosetests)
 
 all: build 
 
+doc:: pydoctor
+
+pydoctor::
+       $(PYDOCTOR) --make-html -c dulwich.cfg
+
 build::
        $(SETUP) build
+       $(SETUP) build_ext -i
 
 install::
        $(SETUP) install
 
-check::
-       PYTHONPATH=. $(TRIAL) dulwich
+check:: build
+       PYTHONPATH=. $(PYTHON) $(TESTRUNNER) dulwich
+
+check-noextensions:: clean
+       PYTHONPATH=. $(PYTHON) $(TESTRUNNER) dulwich
 
 clean::
-       $(SETUP) clean
+       $(SETUP) clean --all
+       rm -f dulwich/*.so
+
+coverage:: build
+       PYTHONPATH=. $(PYTHON) $(TESTRUNNER) --cover-package=dulwich --with-coverage --cover-erase --cover-inclusive dulwich
+
+coverage-annotate: coverage
+       python-coverage -a -o /usr