-
-
Notifications
You must be signed in to change notification settings - Fork 35
Expand file tree
/
Copy pathMakefile
More file actions
66 lines (52 loc) · 1.21 KB
/
Copy pathMakefile
File metadata and controls
66 lines (52 loc) · 1.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# give some default values
ifeq (, $(PYTHON))
PYTHON=python3
endif
COVERAGE ?= $(PYTHON) -m coverage
build:
$(PYTHON) -m build
constants:
$(PYTHON) generate_constants.py > constants.py
mv constants.py src/PyKCS11/
install:
$(PYTHON) -m pip install --editable .
venv:
rm -rf temp
$(PYTHON) -m venv temp
./temp/bin/pip3 install -r dev-requirements.txt
clean distclean:
$(PYTHON) setup.py clean
rm -f src/pykcs11_wrap.cpp
rm -rf build
rm -f *.pyc PyKCS11/*.pyc
rm -f src/PyKCS11/LowLevel.py
rm -f src/PyKCS11/_LowLevel*
rm -f build-stamp
rm -f test/*.pyc
find . -name .DS_Store -exec rm {} \;
src/pykcs11.i: src/opensc/pkcs11.h src/pkcs11lib.h src/pykcs11string.h src/ck_attribute_smart.h
touch $@
pypi: clean
rm -rf dist
$(PYTHON) -m build
$(PYTHON) -m twine upload dist/*
test:
$(PYTHON) run_pytest.py -v
coverage:
$(COVERAGE) erase
$(COVERAGE) run run_test.py
$(COVERAGE) report
$(COVERAGE) html
tox:
./get_PYKCS11LIB.py > tox.env
tox -- -v
pylint:
$(PYTHON) -m pylint PyKCS11
$(PYTHON) -m pylint samples
doc:
cd docs ; ./generate.sh
doc-upload: doc
rm -rf api
mv docs/_build/html api
scp -r api ludov@web.sourceforge.net:/home/project-web/pkcs11wrap/htdocs
.PHONY: build install clean doc test