branch merge
[cython.git] / Makefile
1 PYTHON?=python
2 REPO = http://hg.cython.org/cython-devel
3
4 all:    local 
5
6 local:
7         ${PYTHON} setup.py build_ext --inplace
8
9 .hg: REV := $(shell cat .hgrev)
10 .hg: TMPDIR := $(shell mktemp -d tmprepo.XXXXXX)
11 .hg: 
12         hg clone --rev $(REV) $(REPO) $(TMPDIR)
13         hg -R $(TMPDIR) update
14         mv $(TMPDIR)/.hg .
15         mv $(TMPDIR)/.hgignore .
16         mv $(TMPDIR)/.hgtags .
17         rm -rf $(TMPDIR)
18
19 repo: .hg
20
21
22 clean:
23         @echo Cleaning Source
24         @rm -fr build
25         @rm -f *.py[co] */*.py[co] */*/*.py[co] */*/*/*.py[co]
26         @rm -f *.so */*.so */*/*.so 
27         @rm -f *.pyd */*.pyd */*/*.pyd 
28         @rm -f *~ */*~ */*/*~
29         @rm -f core */core
30         @rm -f Cython/Compiler/*.c
31         @rm -f Cython/Plex/*.c
32         @rm -f Cython/Runtime/refnanny.c
33         @(cd Demos; $(MAKE) clean)
34
35 testclean:
36         rm -fr BUILD
37
38 test:   testclean
39         ${PYTHON} runtests.py -vv
40
41 s5:
42         $(MAKE) -C Doc/s5 slides