Debian Codegraph @

Makefile

raw ◀ ▶
Source reconstructed at patch state 0 of 1 — not the installed (fully patched) source.
1 Debian patch touch this file
1 # Makefile for Kyoto Cabinet for Python
2
3
4 PACKAGE = kyotocabinet-python
5 VERSION = 1.23
6 PACKAGEDIR = $(PACKAGE)-$(VERSION)
7 PACKAGETGZ = $(PACKAGE)-$(VERSION).tar.gz
8
9 PYTHON = python3
10 RUNENV = LD_LIBRARY_PATH=.:/lib:/usr/lib:/usr/local/lib:$(HOME)/lib
11
12
13 all :
14 $(PYTHON) setup.py build
15 cp -f build/*/*.so .
16 @printf '\n'
17 @printf '#================================================================\n'
18 @printf '# Ready to install.\n'
19 @printf '#================================================================\n'
20
21
22 clean :
23 rm -rf casket casket* *~ *.tmp *.kcss *.so *.pyc build hoge moge tako ika
24
25
26 install :
27 $(PYTHON) setup.py install
28 @printf '\n'
29 @printf '#================================================================\n'
30 @printf '# Thanks for using Kyoto Cabinet for Python.\n'
31 @printf '#================================================================\n'
32
33
34 uninstall :
35 $(PYTHON) setup.py install --record files.tmp
36 xargs rm -f < files.tmp
37
38
39 dist :
40 $(MAKE) clean
41 cd .. && tar cvf - $(PACKAGEDIR) | gzip -c > $(PACKAGETGZ)
42
43
44 check :
45 $(MAKE) DBNAME=":" RNUM="10000" check-each
46 $(MAKE) DBNAME="*" RNUM="10000" check-each
47 $(MAKE) DBNAME="%" RNUM="10000" check-each
48 $(MAKE) DBNAME="casket.kch" RNUM="10000" check-each
49 $(MAKE) DBNAME="casket.kct" RNUM="10000" check-each
50 $(MAKE) DBNAME="casket.kcd" RNUM="1000" check-each
51 $(MAKE) DBNAME="casket.kcf" RNUM="10000" check-each
52 @printf '\n'
53 @printf '#================================================================\n'
54 @printf '# Checking completed.\n'
55 @printf '#================================================================\n'
56
57
58 check-each :
59 rm -rf casket*
60 $(RUNENV) $(PYTHON) kctest.py order "$(DBNAME)" "$(RNUM)"
61 $(RUNENV) $(PYTHON) kctest.py order -rnd "$(DBNAME)" "$(RNUM)"
62 $(RUNENV) $(PYTHON) kctest.py order -etc "$(DBNAME)" "$(RNUM)"
63 $(RUNENV) $(PYTHON) kctest.py order -rnd -etc "$(DBNAME)" "$(RNUM)"
64 $(RUNENV) $(PYTHON) kctest.py order -th 4 "$(DBNAME)" "$(RNUM)"
65 $(RUNENV) $(PYTHON) kctest.py order -th 4 -rnd "$(DBNAME)" "$(RNUM)"
66 $(RUNENV) $(PYTHON) kctest.py order -th 4 -etc "$(DBNAME)" "$(RNUM)"
67 $(RUNENV) $(PYTHON) kctest.py order -th 4 -rnd -etc "$(DBNAME)" "$(RNUM)"
68 $(RUNENV) $(PYTHON) kctest.py order -cc -th 4 -rnd -etc "$(DBNAME)" "$(RNUM)"
69 $(RUNENV) $(PYTHON) kctest.py wicked "$(DBNAME)" "$(RNUM)"
70 $(RUNENV) $(PYTHON) kctest.py wicked -it 4 "$(DBNAME)" "$(RNUM)"
71 $(RUNENV) $(PYTHON) kctest.py wicked -th 4 "$(DBNAME)" "$(RNUM)"
72 $(RUNENV) $(PYTHON) kctest.py wicked -th 4 -it 4 "$(DBNAME)" "$(RNUM)"
73 $(RUNENV) $(PYTHON) kctest.py wicked -cc -th 4 -it 4 "$(DBNAME)" "$(RNUM)"
74 $(RUNENV) $(PYTHON) kctest.py misc "$(DBNAME)"
75 rm -rf casket*
76
77
78 check-forever :
79 while true ; \
80 do \
81 $(MAKE) check || break ; \
82 done
83
84
85 doc :
86 $(MAKE) docclean
87 cp -f kyotocabinet-doc.py kyotocabinet.py
88 -[ -f kyotocabinet.so ] && mv -f kyotocabinet.so kyotocabinet-mod.so || true
89 -epydoc --name kyotocabinet --no-private --no-sourcecode -o doc -q kyotocabinet.py
90 -[ -f kyotocabinet-mod.so ] && mv -f kyotocabinet-mod.so kyotocabinet.so || true
91 rm -f kyotocabinet.py
92
93
94 docclean :
95 rm -rf doc
96
97
98 .PHONY: all clean install check doc
99
100
101
102 # END OF FILE