From f413aa33b3f6e4ff51a54f54baf3be9f8757d92c Mon Sep 17 00:00:00 2001 From: Daid Date: Sat, 8 Dec 2012 11:49:53 +0100 Subject: [PATCH] Small makefile change, posibility to add defines on the commandline, and fix compiling with watchdog enabled when using the Makefile. --- Marlin/Makefile | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Marlin/Makefile b/Marlin/Makefile index 6c7417374..56093b001 100644 --- a/Marlin/Makefile +++ b/Marlin/Makefile @@ -190,7 +190,8 @@ SRC = wiring.c \ CXXSRC = WMath.cpp WString.cpp Print.cpp Marlin_main.cpp \ MarlinSerial.cpp Sd2Card.cpp SdBaseFile.cpp SdFatUtil.cpp \ SdFile.cpp SdVolume.cpp motion_control.cpp planner.cpp \ - stepper.cpp temperature.cpp cardreader.cpp ConfigurationStore.cpp + stepper.cpp temperature.cpp cardreader.cpp ConfigurationStore.cpp \ + watchdog.cpp CXXSRC += LiquidCrystal.cpp ultralcd.cpp SPI.cpp #Check for Arduino 1.0.0 or higher and use the correct sourcefiles for that version @@ -212,9 +213,11 @@ DEBUG = stabs OPT = s +DEFINES ?= + # Place -D or -U options here -CDEFS = -DF_CPU=$(F_CPU) -CXXDEFS = -DF_CPU=$(F_CPU) +CDEFS = -DF_CPU=$(F_CPU) ${addprefix -D , $(DEFINES)} +CXXDEFS = -DF_CPU=$(F_CPU) ${addprefix -D , $(DEFINES)} # Add all the source directories as include directories too CINCS = ${addprefix -I ,${VPATH}}