Merge pull request #135 from tuanpmt/master

can set makefile COMPORT name via argument make COMPORT='COM1' flash
This commit is contained in:
Vowstar 2015-01-26 17:51:41 +08:00
commit c9bce72cec
1 changed files with 10 additions and 2 deletions

View File

@ -30,7 +30,11 @@ ifeq ($(OS),Windows_NT)
OBJCOPY = xtensa-lx106-elf-objcopy
endif
FIRMWAREDIR = ..\\bin\\
ESPPORT = com1
ifndef COMPORT
ESPPORT = com1
else
ESPPORT = $(COMPORT)
endif
ifeq ($(PROCESSOR_ARCHITECTURE),AMD64)
# ->AMD64
endif
@ -40,7 +44,11 @@ ifeq ($(OS),Windows_NT)
else
# We are under other system, may be Linux. Assume using gcc.
# Can we use -fdata-sections?
ESPPORT = /dev/ttyUSB0
ifndef COMPORT
ESPPORT = /dev/ttyUSB0
else
ESPPORT = $(COMPORT)
endif
CCFLAGS += -Os -ffunction-sections -fno-jump-tables
AR = xtensa-lx106-elf-ar
CC = xtensa-lx106-elf-gcc