@@ -34,6 +34,7 @@ compiler.elf2hex.flags=-O ihex -R .eeprom
34
34
compiler.elf2hex.cmd=avr-objcopy
35
35
compiler.ldflags=
36
36
compiler.size.cmd=avr-size
37
+ compiler.define=-DARDUINO= -DPLATFORM=
37
38
38
39
# This can be overridden in boards.txt
39
40
build.extra_flags=
@@ -61,13 +62,13 @@ compiler.elf2hex.sketch_flags=
61
62
# --------------------
62
63
63
64
## Compile c files
64
- recipe.c.o.pattern="{compiler.path}{compiler.c.cmd}" {compiler.c.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} {compiler.c.extra_flags} {build.extra_flags} {compiler.c.sketch_flags} {build.sketch_flags} {includes} "{source_file}" -o "{object_file}"
65
+ recipe.c.o.pattern="{compiler.path}{compiler.c.cmd}" {compiler.c.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} -DPLATFORM={version} {compiler.c.extra_flags} {build.extra_flags} {compiler.c.sketch_flags} {build.sketch_flags} {includes} "{source_file}" -o "{object_file}"
65
66
66
67
## Compile c++ files
67
- recipe.cpp.o.pattern="{compiler.path}{compiler.cpp.cmd}" {compiler.cpp.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} {compiler.cpp.extra_flags} {build.extra_flags} {compiler.cpp.sketch_flags} {build.sketch_flags} {includes} "{source_file}" -o "{object_file}"
68
+ recipe.cpp.o.pattern="{compiler.path}{compiler.cpp.cmd}" {compiler.cpp.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} -DPLATFORM={version} {compiler.cpp.extra_flags} {build.extra_flags} {compiler.cpp.sketch_flags} {build.sketch_flags} {includes} "{source_file}" -o "{object_file}"
68
69
69
70
## Compile S files
70
- recipe.S.o.pattern="{compiler.path}{compiler.c.cmd}" {compiler.S.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} {compiler.S.extra_flags} {build.extra_flags} {compiler.S.sketch_flags} {build.sketch_flags} {includes} "{source_file}" -o "{object_file}"
71
+ recipe.S.o.pattern="{compiler.path}{compiler.c.cmd}" {compiler.S.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} -DPLATFORM={version} {compiler.S.extra_flags} {build.extra_flags} {compiler.S.sketch_flags} {build.sketch_flags} {includes} "{source_file}" -o "{object_file}"
71
72
72
73
## Create archives
73
74
# archive_file_path is needed for backwards compatibility with IDE 1.6.5 or older, IDE 1.6.6 or newer overrides this value
@@ -93,10 +94,10 @@ recipe.size.regex.eeprom=^(?:\.eeprom)\s+([0-9]+).*
93
94
94
95
## Preprocessor
95
96
preproc.includes.flags=-w -x c++ -M -MG -MP
96
- recipe.preproc.includes="{compiler.path}{compiler.cpp.cmd}" {compiler.cpp.flags} {preproc.includes.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} {compiler.cpp.extra_flags} {build.extra_flags} {compiler.cpp.sketch_flags} {build.sketch_flags} {includes} "{source_file}"
97
+ recipe.preproc.includes="{compiler.path}{compiler.cpp.cmd}" {compiler.cpp.flags} {preproc.includes.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} -DPLATFORM={version} {compiler.cpp.extra_flags} {build.extra_flags} {compiler.cpp.sketch_flags} {build.sketch_flags} {includes} "{source_file}"
97
98
98
99
preproc.macros.flags=-w -x c++ -E -CC
99
- recipe.preproc.macros="{compiler.path}{compiler.cpp.cmd}" {compiler.cpp.flags} {preproc.macros.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} {compiler.cpp.extra_flags} {build.extra_flags} {compiler.cpp.sketch_flags} {build.sketch_flags} {includes} "{source_file}" -o "{preprocessed_file_path}"
100
+ recipe.preproc.macros="{compiler.path}{compiler.cpp.cmd}" {compiler.cpp.flags} {preproc.macros.flags} -mmcu={build.mcu} -DF_CPU={build.f_cpu} -DARDUINO={runtime.ide.version} -DARDUINO_{build.board} -DARDUINO_ARCH_{build.arch} -DPLATFORM={version} {compiler.cpp.extra_flags} {build.extra_flags} {compiler.cpp.sketch_flags} {build.sketch_flags} {includes} "{source_file}" -o "{preprocessed_file_path}"
100
101
101
102
# AVR Uploader/Programmers tools
102
103
# ------------------------------
0 commit comments