mirror of
https://github.com/cesanta/mongoose.git
synced 2024-12-14 00:31:42 +08:00
129bb6b1c3
PUBLISHED_FROM=57ff02457269938feae805f2972b96b15931d41a
28 lines
724 B
Makefile
28 lines
724 B
Makefile
SDK ?= $(shell cat sdk.version)
|
|
SRC_DIR ?= $(realpath ../../..)
|
|
PORT ?= auto
|
|
|
|
.PHONY: all clean
|
|
|
|
MAKEFLAGS += w
|
|
|
|
all clean:
|
|
docker run --rm -i -v $(SRC_DIR):/src $(SDK) \
|
|
/bin/bash -c "\
|
|
make -C /src/mongoose mongoose.c mongoose.h && \
|
|
make -C /src/mongoose/examples/CC3200 -f Makefile.build $@ -$(MAKEFLAGS) \
|
|
"
|
|
|
|
ifeq ("$(PORT)", "auto")
|
|
PORT = $(shell ls -1 /dev/ttyUSB* | tail -n 1)
|
|
endif
|
|
flash:
|
|
docker run --rm -it --privileged -v $(SRC_DIR):/src $(SDK) /bin/bash -c "\
|
|
cd /usr/local/bin; \
|
|
./cc3200prog $(PORT) /src/smartjs/platforms/cc3200/firmware/smartjs.bin \
|
|
"
|
|
|
|
debug:
|
|
docker run --rm -it --privileged -v $(SRC_DIR):/src $(SDK) \
|
|
/bin/bash -c "cd /src/smartjs/platforms/cc3200 && tools/gdb.sh"
|