Skip to content

Commit ac22923

Browse files
committed
Improve support for assembly programming
1 parent 16ee535 commit ac22923

File tree

2 files changed

+12
-8
lines changed

2 files changed

+12
-8
lines changed

builder/frameworks/esp8266-nonos-sdk.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,12 @@
3131
assert isdir(FRAMEWORK_DIR)
3232

3333
env.Append(
34-
ASFLAGS=["-x", "assembler-with-cpp"],
34+
ASFLAGS=[
35+
"-mlongcalls",
36+
],
37+
ASPPFLAGS=[
38+
"-x", "assembler-with-cpp",
39+
],
3540

3641
CFLAGS=[
3742
"-std=gnu99",
@@ -123,9 +128,6 @@
123128
)
124129
)
125130

126-
# copy CCFLAGS to ASFLAGS (-x assembler-with-cpp mode)
127-
env.Append(ASFLAGS=env.get("CCFLAGS", [])[:])
128-
129131
if not env.BoardConfig().get("build.ldscript", ""):
130132
env.Replace(
131133
LDSCRIPT_PATH=join(FRAMEWORK_DIR, "ld", "eagle.app.v6.ld")

builder/frameworks/esp8266-rtos-sdk.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,12 @@
3232
assert isdir(FRAMEWORK_DIR)
3333

3434
env.Append(
35-
ASFLAGS=["-x", "assembler-with-cpp"],
35+
ASFLAGS=[
36+
"-mlongcalls",
37+
],
38+
ASPPFLAGS=[
39+
"-x", "assembler-with-cpp",
40+
],
3641

3742
CFLAGS=[
3843
"-std=gnu99",
@@ -124,9 +129,6 @@
124129
)
125130
)
126131

127-
# copy CCFLAGS to ASFLAGS (-x assembler-with-cpp mode)
128-
env.Append(ASFLAGS=env.get("CCFLAGS", [])[:])
129-
130132
if not env.BoardConfig().get("build.ldscript", ""):
131133
env.Replace(
132134
LDSCRIPT_PATH=join(FRAMEWORK_DIR, "ld", "eagle.app.v6.ld"),

0 commit comments

Comments
 (0)