2
2
.PHONY : release sdist-libuv docs
3
3
4
4
5
+ PYTHON ?= python
6
+
7
+
5
8
all : compile
6
9
7
10
13
16
14
17
15
18
check-env :
16
- python -c " import cython; (cython.__version__ < '0.24') and exit(1)"
19
+ $( PYTHON ) -c " import cython; (cython.__version__ < '0.24') and exit(1)"
17
20
18
21
19
22
clean-libuv :
@@ -30,32 +33,32 @@ distclean: clean clean-libuv
30
33
compile : check-env clean
31
34
echo " DEF DEBUG = 0" > uvloop/__debug.pxi
32
35
cython -3 uvloop/loop.pyx; rm uvloop/__debug.*
33
- @echo " $$ UVLOOP_BUILD_PATCH_SCRIPT" | python
34
- python setup.py build_ext --inplace
36
+ @echo " $$ UVLOOP_BUILD_PATCH_SCRIPT" | $( PYTHON )
37
+ $( PYTHON ) setup.py build_ext --inplace
35
38
36
39
37
40
debug : check-env clean
38
41
echo " DEF DEBUG = 1" > uvloop/__debug.pxi
39
42
cython -3 -a -p uvloop/loop.pyx; rm uvloop/__debug.*
40
- @echo " $$ UVLOOP_BUILD_PATCH_SCRIPT" | python
41
- python setup.py build_ext --inplace
43
+ @echo " $$ UVLOOP_BUILD_PATCH_SCRIPT" | $( PYTHON )
44
+ $( PYTHON ) setup.py build_ext --inplace
42
45
43
46
44
47
docs : compile
45
- cd docs && python -m sphinx -a -b html . _build/html
48
+ cd docs && $( PYTHON ) -m sphinx -a -b html . _build/html
46
49
47
50
48
51
test :
49
- PYTHONASYNCIODEBUG =1 python -m unittest discover -s tests
50
- python -m unittest discover -s tests
52
+ $( PYTHON ) ASYNCIODEBUG =1 $( PYTHON ) -m unittest discover -s tests
53
+ $( PYTHON ) -m unittest discover -s tests
51
54
52
55
53
56
sdist : clean compile test sdist-libuv
54
- python setup.py sdist
57
+ $( PYTHON ) setup.py sdist
55
58
56
59
57
60
release : clean compile test sdist-libuv
58
- python setup.py sdist bdist_wheel upload
61
+ $( PYTHON ) setup.py sdist bdist_wheel upload
59
62
60
63
61
64
# Script to patch Cython 'async def' coroutines to have a 'tp_iter' slot,
0 commit comments