diff options
| author | Sudar <sudar@sudarmuthu.com> | 2014-10-24 09:02:51 +0530 |
|---|---|---|
| committer | Sudar <sudar@sudarmuthu.com> | 2014-10-24 09:02:51 +0530 |
| commit | 3eee9851bb176d0695d3dd091d6ebf8412ac382f (patch) | |
| tree | 8df90c03c25ecc0a83eb21af64846b135223401a /Common.mk | |
| parent | 8d443f62c88e4f211dbfeab33df876887fa0f53b (diff) | |
| parent | daacad1d77306a37d3df5423feca27d3f5d730f7 (diff) | |
Merge pull request #281 from stepcut/teensy.mk
Add support for Teensyduino 3.x
Diffstat (limited to 'Common.mk')
| -rw-r--r-- | Common.mk | 23 |
1 files changed, 23 insertions, 0 deletions
@@ -61,3 +61,26 @@ ifneq ($(TEST),) ARDUINO_DIR = $(DEPENDENCIES_ARDUINO_DIR) endif endif + +######################################################################## +# Arduino Directory + +ifndef ARDUINO_DIR + AUTO_ARDUINO_DIR := $(firstword \ + $(call dir_if_exists,/usr/share/arduino) \ + $(call dir_if_exists,/Applications/Arduino.app/Contents/Resources/Java) ) + ifdef AUTO_ARDUINO_DIR + ARDUINO_DIR = $(AUTO_ARDUINO_DIR) + $(call show_config_variable,ARDUINO_DIR,[AUTODETECTED]) + else + echo $(error "ARDUINO_DIR is not defined") + endif +else + $(call show_config_variable,ARDUINO_DIR,[USER]) +endif + +ifeq ($(CURRENT_OS),WINDOWS) + ifneq ($(shell echo $(ARDUINO_DIR) | egrep '^(/|[a-zA-Z]:\\)'),) + echo $(error On Windows, ARDUINO_DIR must be a relative path) + endif +endif |
