Update espressif platform

This commit is contained in:
Valeriy Koval
2015-04-07 19:44:28 +03:00
parent 960eccad8c
commit 0ff3e8a9eb
7 changed files with 8 additions and 487 deletions
+8 -21
View File
@@ -35,6 +35,7 @@ env.Replace(
"-Wpointer-arith",
"-Wno-implicit-function-declaration",
"-Wl,-EL",
"-fno-inline-functions",
"-nostdlib"
],
@@ -57,6 +58,11 @@ env.Replace(
"ICACHE_FLASH"
],
CPPPATH=[
join("$PIOPACKAGES_DIR", "sdk-esp8266", "include"),
"$PROJECTSRC_DIR"
],
LINKFLAGS=[
"-nostdlib",
"-Wl,--no-check-section",
@@ -64,7 +70,8 @@ env.Replace(
"-Wl,-static"
],
LIBS=["c", "gcc"],
LIBPATH=[join("$PIOPACKAGES_DIR", "sdk-esp8266", "lib")],
LIBS=["c", "gcc", "hal", "phy", "net80211", "lwip", "wpa", "main", "pp"],
SIZEPRINTCMD='"$SIZETOOL" -B -d $SOURCES',
@@ -102,26 +109,6 @@ env.Append(
)
)
#
# Configure SDK
#
if "FRAMEWORK" not in env:
env.Append(
CPPPATH=[
join("$PIOPACKAGES_DIR", "sdk-esp8266", "include"),
"$PROJECTSRC_DIR"
],
LIBPATH=[join("$PIOPACKAGES_DIR", "sdk-esp8266", "lib")],
LIBS=["at", "json", "lwip", "main", "net80211", "phy", "pp",
"smartconfig", "ssl", "upgrade", "wpa"]
)
env.Replace(
LDSCRIPT_PATH=join(
"$PIOPACKAGES_DIR", "sdk-esp8266", "ld", "eagle.app.v6.ld")
)
#
# Target: Build executable and linkable firmware
#
@@ -42,14 +42,6 @@ elif env.get("PLATFORM") == "timsp430":
"$PIOPACKAGES_DIR",
"framework-arduinomsp430"
)
elif env.get("PLATFORM") == "espressif":
PLATFORMFW_DIR = join(
"$PIOPACKAGES_DIR",
"framework-arduinoespressif"
)
env.Append(
CPPPATH=[join("$PLATFORMFW_DIR", "sdk", "include")]
)
env.Replace(PLATFORMFW_DIR=PLATFORMFW_DIR)
@@ -203,14 +195,12 @@ libs.append(envsafe.BuildLibrary(
))
if env.subst("${PLATFORMFW_DIR}")[-3:] == "sam":
env.Append(
LIBPATH=[
join("$PLATFORMFW_DIR", "variants",
"${BOARD_OPTIONS['build']['variant']}")
]
)
envsafe.Append(
CFLAGS=[
"-std=gnu99"
@@ -218,10 +208,4 @@ if env.subst("${PLATFORMFW_DIR}")[-3:] == "sam":
)
libs.append("sam_sam3x8e_gcc_rel")
elif env.get("PLATFORM") == "espressif":
env.Append(
LIBPATH=[join("$PLATFORMFW_DIR", "sdk", "lib")]
)
libs.extend(["hal", "phy", "net80211", "lwip", "wpa", "main", "pp"])
env.Append(LIBS=libs)