@ -1,4 +1,5 @@
HERE := $( dir $( lastword $( MAKEFILE_LIST) ) )
HERE := $( dir $( lastword $( MAKEFILE_LIST) ) )
- i n c l u d e $( HERE ) b u i l d . c o n f
# Project Name
# Project Name
TARGET ?= blink
TARGET ?= blink
@ -7,29 +8,20 @@ TARGET?=blink
# common configurations:
# common configurations:
# use DEBUG = 1 and OPT = -Og for debugging
# use DEBUG = 1 and OPT = -Og for debugging
# or DEBUG = 0 and OPT = -O3 for performance
# or DEBUG = 0 and OPT = -O3 for performance
DEBUG = 0
DEBUG ? =0
OPT = -O3
OPT ? = -O3
# (optional) Includes FatFS source files within project.
# (optional) Includes FatFS source files within project.
#USE_FATFS = 1
#USE_FATFS = 1
# Relative to dir 'src'
# Relative to dir 'src'
LIBDAISY_DIR = ../../heck_libDaisy
LIBDAISY_DIR ? = ../../heck_libDaisy
DAISYSP_DIR = ../../heck_DaisySP
DAISYSP_DIR ? = ../../heck_DaisySP
CXXFLAGS += -Wall -Wno-unused -Wno-reorder-ctor -Wno-switch
CXXFLAGS += -Wall -Wno-unused -Wno-reorder-ctor -Wno-switch
######### Overrides from build.conf #########
- i n c l u d e $( HERE ) b u i l d . c o n f
i f n e q ( , $( findstring g ++,$ ( CXX ) ) )
i f n e q ( , $( findstring g ++,$ ( CXX ) ) )
CXXFLAGS += -fdiagnostics-color= always
CXXFLAGS += -fdiagnostics-color= always
e l s e i f n e q ( , $( findstring clang ,$ ( CXX ) ) )
e l s e i f n e q ( , $( findstring clang ,$ ( CXX ) ) )
CXXFLAGS += -fcolor-diagnostics
CXXFLAGS += -fcolor-diagnostics
e n d i f
e n d i f
i f e q ( $( DEBUG ) , 1 )
CXXFLAGS += -g -O0
e l s e
CXXFLAGS += -DNDEBUG= 1 -O3
e n d i f