-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathGNUmakefile
More file actions
25 lines (19 loc) · 808 Bytes
/
Copy pathGNUmakefile
File metadata and controls
25 lines (19 loc) · 808 Bytes
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
SUBDIRS := esp8266 host mailstation
DOWNLOAD_URL := "https://raw.githubusercontent.com/jcs/WiFiStation/main/release/wifistation.bin"
VERSION := $(shell grep 'define WIFISTATION_VERSION' esp8266/wifistation.h | sed 's/.*"\(.*\)"/\1/')
all: $(SUBDIRS)
$(SUBDIRS):
$(MAKE) -C $@
clean:
for f in $(SUBDIRS); do $(MAKE) -C $$f clean; done
flash_esp8266: esp8266
env UPLOAD_PORT=/dev/cuaU0 $(MAKE) -C esp8266 flash
release: all
cp -f esp8266/obj/wifistation_huzzah/wifistation.bin release/
cp -f mailstation/wsloader.bin release/
cp -f mailstation/flashloader.bin release/
echo $(VERSION) > release/version.txt
stat -f "%z" release/wifistation.bin >> release/version.txt
md5 -q release/wifistation.bin >> release/version.txt
echo $(DOWNLOAD_URL) >> release/version.txt
.PHONY: all clean $(SUBDIRS)