diff --git a/tools/platformio-build.py b/tools/platformio-build.py index a462ff391..56d5e8464 100644 --- a/tools/platformio-build.py +++ b/tools/platformio-build.py @@ -59,7 +59,13 @@ if gzip_fw: gzip_switch = ["--gzip", "PIO"] env.Append( - ASFLAGS=["-x", "assembler-with-cpp"], + ASFLAGS=[ + "-mlongcalls", + "-mtext-section-literals", + ], + ASPPFLAGS=[ + "-x", "assembler-with-cpp", + ], # General options that are passed to the C compiler (C only; not C++) CFLAGS=[ @@ -166,9 +172,6 @@ env.Append( ) ) -# copy CCFLAGS to ASFLAGS (-x assembler-with-cpp mode) -env.Append(ASFLAGS=env.get("CCFLAGS", [])[:]) - flatten_cppdefines = env.Flatten(env['CPPDEFINES']) #