mirror of
https://github.com/platformio/platformio-core.git
synced 2025-07-31 18:44:27 +02:00
Refactor platform build scripts // Resolve #528
This commit is contained in:
@@ -120,7 +120,7 @@ if "due" in env.subst("$BOARD"):
|
||||
)
|
||||
elif "zero" in env.subst("$BOARD"):
|
||||
env.Append(
|
||||
CPPFLAGS=[
|
||||
CCFLAGS=[
|
||||
"--param", "max-inline-insns-single=500"
|
||||
],
|
||||
|
||||
|
@@ -31,9 +31,12 @@ env.Replace(
|
||||
|
||||
ARFLAGS=["rcs"],
|
||||
|
||||
ASPPFLAGS=["-x", "assembler-with-cpp"],
|
||||
ASFLAGS=[
|
||||
"-x", "assembler-with-cpp",
|
||||
"$CCFLAGS"
|
||||
],
|
||||
|
||||
CPPFLAGS=[
|
||||
CCFLAGS=[
|
||||
"-g", # include debugging info (so errors include line numbers)
|
||||
"-Os", # optimize for size
|
||||
"-ffunction-sections", # place each function in its own section
|
||||
|
@@ -31,9 +31,12 @@ env.Replace(
|
||||
|
||||
ARFLAGS=["rcs"],
|
||||
|
||||
ASPPFLAGS=["-x", "assembler-with-cpp"],
|
||||
ASFLAGS=[
|
||||
"-x", "assembler-with-cpp",
|
||||
"$CCFLAGS"
|
||||
],
|
||||
|
||||
CPPFLAGS=[
|
||||
CCFLAGS=[
|
||||
"-g", # include debugging info (so errors include line numbers)
|
||||
"-Os", # optimize for size
|
||||
"-Wall", # show warnings
|
||||
|
@@ -64,7 +64,10 @@ env.Replace(
|
||||
|
||||
ARFLAGS=["rcs"],
|
||||
|
||||
ASPPFLAGS=["-x", "assembler-with-cpp"],
|
||||
ASFLAGS=[
|
||||
"-x", "assembler-with-cpp",
|
||||
"$CCFLAGS"
|
||||
],
|
||||
|
||||
CFLAGS=[
|
||||
"-std=gnu99",
|
||||
@@ -75,7 +78,7 @@ env.Replace(
|
||||
"-nostdlib"
|
||||
],
|
||||
|
||||
CPPFLAGS=[
|
||||
CCFLAGS=[
|
||||
"-Os", # optimize for size
|
||||
"-mlongcalls",
|
||||
"-mtext-section-literals",
|
||||
|
@@ -27,7 +27,7 @@ SConscript(env.subst(join("$PIOBUILDER_DIR", "scripts", "basearm.py")))
|
||||
|
||||
if env.subst("$BOARD") == "rfduino":
|
||||
env.Append(
|
||||
CPPFLAGS=["-fno-builtin"],
|
||||
CCFLAGS=["-fno-builtin"],
|
||||
LINKFLAGS=["--specs=nano.specs"]
|
||||
)
|
||||
env.Replace(
|
||||
|
@@ -31,7 +31,7 @@ elif env.get("BOARD_OPTIONS", {}).get("build", {}).get("core") == "teensy3":
|
||||
LINKFLAGS=[
|
||||
"-Wl,--defsym=__rtc_localtime=$UNIX_TIME"
|
||||
],
|
||||
CPPFLAGS=[
|
||||
CCFLAGS=[
|
||||
"-fsingle-precision-constant"
|
||||
]
|
||||
)
|
||||
|
@@ -36,7 +36,10 @@ env.Replace(
|
||||
|
||||
ARFLAGS=["rcs"],
|
||||
|
||||
ASPPFLAGS=["-x", "assembler-with-cpp"],
|
||||
ASFLAGS=[
|
||||
"-x", "assembler-with-cpp",
|
||||
"$CCFLAGS"
|
||||
],
|
||||
|
||||
CCFLAGS=[
|
||||
"-g", # include debugging info (so errors include line numbers)
|
||||
|
Reference in New Issue
Block a user