1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-06-13 13:01:55 +03:00

Drop PlatformIO lines from LD script; append object suffix to the end of target name // Resolve #4355

This commit is contained in:
Ivan Kravets
2018-02-20 13:40:54 +02:00
parent ee5a1e2804
commit f2fc590d51
2 changed files with 16 additions and 23 deletions

View File

@ -26,8 +26,23 @@ http://arduino.cc/en/Reference/HomePage
from os.path import isdir, join
from SCons import Builder, Util
from SCons.Script import DefaultEnvironment
def scons_patched_match_splitext(path, suffixes=None):
"""
Patch SCons Builder, append $OBJSUFFIX to the end of each target
"""
tokens = Util.splitext(path)
if suffixes and tokens[1] and tokens[1] in suffixes:
return (path, tokens[1])
return tokens
Builder.match_splitext = scons_patched_match_splitext
env = DefaultEnvironment()
platform = env.PioPlatform()
@ -92,4 +107,4 @@ libs.append(env.BuildLibrary(
join(FRAMEWORK_DIR, "cores", env.BoardConfig().get("build.core"))
))
env.Prepend(LIBS=libs)
env.Prepend(LIBS=libs)