Modified Arduino.mk to use correct upload protocol if not overrided.

The previous comment of upload protocol not working cannot be verified on
linux. If this problem persists on cygwin, please override with
UPLOAD_PROTOCOL=arduino in the enivornment before calling Arduino.mk
This commit is contained in:
James Goppert 2011-09-22 13:35:26 -04:00
parent 926416040b
commit 90a3a5b1e5
1 changed files with 2 additions and 3 deletions

View File

@ -325,10 +325,9 @@ MCU := $(shell grep $(BOARD).build.mcu $(BOARDFILE) | cut -d = -f 2)
F_CPU := $(shell grep $(BOARD).build.f_cpu $(BOARDFILE) | cut -d = -f 2) F_CPU := $(shell grep $(BOARD).build.f_cpu $(BOARDFILE) | cut -d = -f 2)
HARDWARE_CORE := $(shell grep $(BOARD).build.core $(BOARDFILE) | cut -d = -f 2) HARDWARE_CORE := $(shell grep $(BOARD).build.core $(BOARDFILE) | cut -d = -f 2)
UPLOAD_SPEED := $(shell grep $(BOARD).upload.speed $(BOARDFILE) | cut -d = -f 2) UPLOAD_SPEED := $(shell grep $(BOARD).upload.speed $(BOARDFILE) | cut -d = -f 2)
# This simply does not work, so hardcode it to the correct value
#UPLOAD_PROTOCOL := $(shell grep $(BOARD).upload.protocol $(BOARDFILE) | cut -d = -f 2)
ifeq ($(UPLOAD_PROTOCOL),) ifeq ($(UPLOAD_PROTOCOL),)
UPLOAD_PROTOCOL := arduino UPLOAD_PROTOCOL := $(shell grep $(BOARD).upload.protocol $(BOARDFILE) | cut -d = -f 2)
endif endif
ifeq ($(MCU),) ifeq ($(MCU),)