1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-04-21 10:26:06 +03:00

Merge pull request #4399 from ivankravets/master

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 15:01:57 +02:00 committed by GitHub
commit e5746c0f5a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
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 os.path import isdir, join
from SCons import Builder, Util
from SCons.Script import DefaultEnvironment 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() env = DefaultEnvironment()
platform = env.PioPlatform() platform = env.PioPlatform()

View File

@ -91,17 +91,6 @@ SECTIONS
*.c.o( EXCLUDE_FILE (umm_malloc.c.o) .literal*, \ *.c.o( EXCLUDE_FILE (umm_malloc.c.o) .literal*, \
EXCLUDE_FILE (umm_malloc.c.o) .text*) EXCLUDE_FILE (umm_malloc.c.o) .text*)
*.cpp.o(.literal*, .text*) *.cpp.o(.literal*, .text*)
/* PlatformIO */
/* framework */
*.pioenvs\\*\\lib*.a:(EXCLUDE_FILE (umm_malloc.o) .literal*, EXCLUDE_FILE (umm_malloc.o) .text*)
*.pioenvs/*/lib*.a:(EXCLUDE_FILE (umm_malloc.o) .literal*, EXCLUDE_FILE (umm_malloc.o) .text*)
/* project dependencies */
*.pioenvs\\*\\lib*\\lib*.a:(.literal*, .text*)
*.pioenvs/*/lib*/lib*.a:(.literal*, .text*)
/* project source objects */
*.pioenvs\\*\\src\\*.o(.literal*, .text*)
*.pioenvs/*/src/*.o(.literal*, .text*)
/* End PlatformIO */
*libc.a:(.literal .text .literal.* .text.*) *libc.a:(.literal .text .literal.* .text.*)
*libm.a:(.literal .text .literal.* .text.*) *libm.a:(.literal .text .literal.* .text.*)
*libgcc.a:_umoddi3.o(.literal .text) *libgcc.a:_umoddi3.o(.literal .text)
@ -166,17 +155,6 @@ SECTIONS
*.cpp.o(.iram.text) *.cpp.o(.iram.text)
*.c.o(.iram.text) *.c.o(.iram.text)
*(.rodata._ZTV*) /* C++ vtables */ *(.rodata._ZTV*) /* C++ vtables */
/* PlatformIO */
/* framework */
*.pioenvs\\*\\lib*.a:(.iram.text)
*.pioenvs/*/lib*.a:(.iram.text)
/* project dependencies */
*.pioenvs\\*\\lib*\\lib*.a:(.iram.text)
*.pioenvs/*/lib*/lib*.a:(.iram.text)
/* project source objects */
*.pioenvs\\*\\src\\*.o(.iram.text)
*.pioenvs/*/src/*.o(.iram.text)
/* End PlatformIO */
*(.fini.literal) *(.fini.literal)
*(.fini) *(.fini)
*(.gnu.version) *(.gnu.version)