Remove redundant checks for ARDUINO_DIR

This commit is contained in:
Sudar 2013-06-23 13:16:37 +05:30
parent 7e66672a6c
commit 700f82b3f1
2 changed files with 61 additions and 65 deletions

View file

@ -9,6 +9,7 @@ The following is the rough list of changes that went into different versions. I
- Add support for reseting "Micro" Arduino. Fix issue #80 (https://github.com/sej7278) - Add support for reseting "Micro" Arduino. Fix issue #80 (https://github.com/sej7278)
- Remove "utility" from example makefiles. Fix issue #84 - Remove "utility" from example makefiles. Fix issue #84
- Auto detect alternate core path from sketchbook folder. Fix issue #86 - Auto detect alternate core path from sketchbook folder. Fix issue #86
- Remove redundant checks for ARDUINO_DIR
### 0.12.0 (2013-06-20) ### 0.12.0 (2013-06-20)
- Fix "generated_assembly" target, which got broken earlier. Fix issue #76 (https://github.com/matthijskooijman) - Fix "generated_assembly" target, which got broken earlier. Fix issue #76 (https://github.com/matthijskooijman)

View file

@ -238,8 +238,9 @@ ifndef ARDUINO_DIR
ifdef AUTO_ARDUINO_DIR ifdef AUTO_ARDUINO_DIR
ARDUINO_DIR = $(AUTO_ARDUINO_DIR) ARDUINO_DIR = $(AUTO_ARDUINO_DIR)
$(call show_config_variable,ARDUINO_DIR,[AUTODETECTED]) $(call show_config_variable,ARDUINO_DIR,[AUTODETECTED])
else
echo $(error "ARDUINO_DIR is not defined")
endif endif
else else
$(call show_config_variable,ARDUINO_DIR,[USER]) $(call show_config_variable,ARDUINO_DIR,[USER])
endif endif
@ -300,9 +301,7 @@ endif
######################################################################## ########################################################################
# Arduino and system paths # Arduino and system paths
# #
ifdef ARDUINO_DIR ifndef AVR_TOOLS_DIR
ifndef AVR_TOOLS_DIR
BUNDLED_AVR_TOOLS_DIR := $(call dir_if_exists,$(ARDUINO_DIR)/hardware/tools/avr) BUNDLED_AVR_TOOLS_DIR := $(call dir_if_exists,$(ARDUINO_DIR)/hardware/tools/avr)
ifdef BUNDLED_AVR_TOOLS_DIR ifdef BUNDLED_AVR_TOOLS_DIR
@ -321,24 +320,24 @@ ifdef ARDUINO_DIR
endif # BUNDLED_AVR_TOOLS_DIR endif # BUNDLED_AVR_TOOLS_DIR
else else
$(call show_config_variable,AVR_TOOLS_DIR,[USER]) $(call show_config_variable,AVR_TOOLS_DIR,[USER])
endif #ndef AVR_TOOLS_DIR endif #ndef AVR_TOOLS_DIR
ARDUINO_LIB_PATH = $(ARDUINO_DIR)/libraries ARDUINO_LIB_PATH = $(ARDUINO_DIR)/libraries
$(call show_config_variable,ARDUINO_LIB_PATH,[COMPUTED],(from ARDUINO_DIR)) $(call show_config_variable,ARDUINO_LIB_PATH,[COMPUTED],(from ARDUINO_DIR))
ARDUINO_CORE_PATH = $(ARDUINO_DIR)/hardware/arduino/cores/arduino ARDUINO_CORE_PATH = $(ARDUINO_DIR)/hardware/arduino/cores/arduino
# Third party hardware and core like ATtiny or ATmega 16 # Third party hardware and core like ATtiny or ATmega 16
ifdef ALTERNATE_CORE ifdef ALTERNATE_CORE
$(call show_config_variable,ALTERNATE_CORE,[USER]) $(call show_config_variable,ALTERNATE_CORE,[USER])
ifndef ALTERNATE_CORE_PATH ifndef ALTERNATE_CORE_PATH
ALTERNATE_CORE_PATH = $(ARDUINO_SKETCHBOOK)/hardware/$(ALTERNATE_CORE) ALTERNATE_CORE_PATH = $(ARDUINO_SKETCHBOOK)/hardware/$(ALTERNATE_CORE)
endif endif
endif endif
ifdef ALTERNATE_CORE_PATH ifdef ALTERNATE_CORE_PATH
ifdef ALTERNATE_CORE ifdef ALTERNATE_CORE
$(call show_config_variable,ALTERNATE_CORE_PATH,[COMPUTED], (from ARDUINO_SKETCHBOOK and ALTERNATE_CORE)) $(call show_config_variable,ALTERNATE_CORE_PATH,[COMPUTED], (from ARDUINO_SKETCHBOOK and ALTERNATE_CORE))
@ -356,7 +355,7 @@ ifdef ARDUINO_DIR
$(call show_config_variable,BOARDS_TXT,[COMPUTED],(from ALTERNATE_CORE_PATH)) $(call show_config_variable,BOARDS_TXT,[COMPUTED],(from ALTERNATE_CORE_PATH))
endif endif
else else
ifndef ARDUINO_VAR_PATH ifndef ARDUINO_VAR_PATH
ARDUINO_VAR_PATH = $(ARDUINO_DIR)/hardware/arduino/variants ARDUINO_VAR_PATH = $(ARDUINO_DIR)/hardware/arduino/variants
@ -372,10 +371,6 @@ ifdef ARDUINO_DIR
$(call show_config_variable,BOARDS_TXT,[USER]) $(call show_config_variable,BOARDS_TXT,[USER])
endif endif
endif
else
echo $(error "ARDUINO_DIR is not defined")
endif endif
ifdef AVR_TOOLS_DIR ifdef AVR_TOOLS_DIR