-
Notifications
You must be signed in to change notification settings - Fork 4
/
Makefile
48 lines (35 loc) · 1.19 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
.PHONY: all target config build clean flash erase-ota app-flash monitor cppcheck pipenv
PIPENV=$(CURDIR)/pipenv
PYTHON=$(PIPENV)/.venv/bin/python
all: build
target:
idf.py set-target esp32c6
config:
idf.py menuconfig
build:
idf.py build
clean:
idf.py clean
+$(MAKE) -C $(PIPENV) -L clean
flash: build
idf.py flash
erase-ota:
idf.py erase-otadata
app-flash: build
idf.py app-flash
monitor:
idf.py monitor --timestamps --timestamp-format "%Y-%m-%d %H:%M:%S.%f" --no-reset
cppcheck:
cppcheck --enable=all --suppress=unusedFunction --suppress=useStlAlgorithm \
--suppress=knownConditionTrueFalse --suppress=missingIncludeSystem \
--suppress=internalAstError --inline-suppr -I src/ src/*.cpp
pipenv:
+$(MAKE) -C $(PIPENV) -L
build/candle-dribbler.ota: build/candle-dribbler.bin build/config/sdkconfig.h bin/create-ota.py Makefile | pipenv
rm -f $@~
$(PYTHON) bin/create-ota.py \
-m $(shell grep -F CONFIG_NUTT_OTA_MANUFACTURER_ID build/config/sdkconfig.h | cut -d ' ' -f 3) \
-i $(shell grep -F CONFIG_NUTT_OTA_IMAGE_TYPE_ID build/config/sdkconfig.h | cut -d ' ' -f 3) \
-v $(shell grep -F CONFIG_NUTT_OTA_FILE_VERSION build/config/sdkconfig.h | cut -d ' ' -f 3) \
-- $< $@~
mv $@~ $@