-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
78 lines (68 loc) · 1.68 KB
/
Makefile
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
67
68
69
70
71
72
73
74
75
76
77
78
PSDB_VERS := 1.1.5
PSDB_DEPS := \
setup.cfg \
setup.py \
psdb/*.py \
psdb/block/*.py \
psdb/component/*.py \
psdb/cpus/*.py \
psdb/devices/*.py \
psdb/devices/core/*.py \
psdb/devices/msp432/*.py \
psdb/devices/stm32/*.py \
psdb/devices/stm32c0/*.py \
psdb/devices/stm32g0/*.py \
psdb/devices/stm32g4/*.py \
psdb/devices/stm32h7/*.py \
psdb/devices/stm32u5/*.py \
psdb/devices/stm32wb55/*.py \
psdb/devices/stm32wb55/ipc/*.py \
psdb/elf/*.py \
psdb/hexfile/*.py \
psdb/inspect_tool/*.py \
psdb/probes/*.py \
psdb/probes/stlink/*.py \
psdb/probes/xds110/*.py \
psdb/probes/xtswd/*.py \
psdb/targets/*.py \
psdb/targets/msp432/*.py \
psdb/targets/stm32c0/*.py \
psdb/targets/stm32g0/*.py \
psdb/targets/stm32g4/*.py \
psdb/targets/stm32h7/*.py \
psdb/targets/stm32u5/*.py \
psdb/targets/stm32wb55/*.py \
psdb/util/*.py
PYTHON := python3
.PHONY: all
all: psdb
.PHONY: clean
clean:
rm -rf dist psdb.egg-info build
find . -name "*.pyc" | xargs rm
find . -name __pycache__ | xargs rm -r
.PHONY: test
test: flake8
.PHONY: flake8
flake8:
$(PYTHON) -m flake8 psdb
.PHONY: lint
lint:
$(PYTHON) -m pylint -j2 psdb
.PHONY: psdb
psdb: dist/psdb-$(PSDB_VERS)-py3-none-any.whl
.PHONY: install
install: psdb
sudo $(PYTHON) -m pip uninstall -y psdb
sudo $(PYTHON) -m pip install dist/psdb-$(PSDB_VERS)-py3-none-any.whl
.PHONY: uninstall
uninstall:
sudo $(PYTHON) -m pip uninstall psdb
.PHONY: publish
publish: psdb
$(PYTHON) -m twine upload \
dist/psdb-$(PSDB_VERS)-py3-none-any.whl \
dist/psdb-$(PSDB_VERS).tar.gz
dist/psdb-$(PSDB_VERS)-py3-none-any.whl: $(PSDB_DEPS) Makefile
$(PYTHON) -m build
$(PYTHON) -m twine check $@