Merge pull request #127 from aozima/pulls

update linker script and SConstruct.
This commit is contained in:
Bernard Xiong 2013-07-11 15:53:44 -07:00
commit a5a36d3fbf
46 changed files with 665 additions and 621 deletions

View File

@ -34,8 +34,5 @@ if GetDepend('RT_USING_RTGUI'):
# libc testsuite # libc testsuite
objs = objs + SConscript(RTT_ROOT + '/examples/libc/SConscript', variant_dir='build/examples/libc', duplicate=0) objs = objs + SConscript(RTT_ROOT + '/examples/libc/SConscript', variant_dir='build/examples/libc', duplicate=0)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -23,6 +23,12 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
/* section information for modules */ /* section information for modules */
. = ALIGN(4); . = ALIGN(4);
__rtmsymtab_start = .; __rtmsymtab_start = .;

View File

@ -28,8 +28,5 @@ objs = PrepareBuilding(env, RTT_ROOT)
# AVR32 software framework building script # AVR32 software framework building script
objs = objs + SConscript(RTT_ROOT + '/bsp/avr32uc3b0/SOFTWARE_FRAMEWORK/SConscript', variant_dir='bsp/SOFTWARE_FRAMEWORK', duplicate=0) objs = objs + SConscript(RTT_ROOT + '/bsp/avr32uc3b0/SOFTWARE_FRAMEWORK/SConscript', variant_dir='bsp/SOFTWARE_FRAMEWORK', duplicate=0)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -25,8 +25,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT) objs = PrepareBuilding(env, RTT_ROOT)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -31,8 +31,5 @@ objs = objs + SConscript(RTT_ROOT + '/bsp/efm32/EFM32GG_DK3750/SConscript', vari
objs = objs + SConscript(RTT_ROOT + '/bsp/efm32/graphics/SConscript', variant_dir='build/graphics', duplicate=0) objs = objs + SConscript(RTT_ROOT + '/bsp/efm32/graphics/SConscript', variant_dir='build/graphics', duplicate=0)
objs = objs + SConscript(RTT_ROOT + '/bsp/efm32/Libraries/SConscript', variant_dir='build/Libraries', duplicate=0) objs = objs + SConscript(RTT_ROOT + '/bsp/efm32/Libraries/SConscript', variant_dir='build/Libraries', duplicate=0)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -88,6 +88,13 @@ SECTIONS
__vsymtab_start = .; __vsymtab_start = .;
KEEP(*(VSymTab)) KEEP(*(VSymTab))
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
} > FLASH = 0 } > FLASH = 0
.ARM.extab : .ARM.extab :

View File

@ -6,7 +6,7 @@ src_bsp = ['application.c', 'startup.c', 'board.c']
src_drv = ['uart.c'] src_drv = ['uart.c']
src = File(src_bsp + src_drv) src = File(src_bsp + src_drv)
CPPPATH = Dir('#') CPPPATH = str(Dir('#'))
group = DefineGroup('Startup', src, depend = [''], CPPPATH = CPPPATH) group = DefineGroup('Startup', src, depend = [''], CPPPATH = CPPPATH)
Return('group') Return('group')

View File

@ -25,8 +25,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT) objs = PrepareBuilding(env, RTT_ROOT)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -25,7 +25,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False) objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
env.Program(TARGET, objs) # make a building
DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -37,6 +37,12 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
_etext = .; _etext = .;
} > CODE = 0 } > CODE = 0

View File

@ -25,8 +25,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False) objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -37,6 +37,12 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
_etext = .; _etext = .;
} > CODE = 0 } > CODE = 0

View File

@ -25,8 +25,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False) objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -50,6 +50,12 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
} > FLASH } > FLASH
.data : AT(ADDR(.text) + SIZEOF(.text)) .data : AT(ADDR(.text) + SIZEOF(.text))

View File

@ -36,9 +36,10 @@ SECTIONS
__vsymtab_start = .; __vsymtab_start = .;
KEEP(*(VSymTab)) KEEP(*(VSymTab))
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
__rt_init_start = .; __rt_init_start = .;
KEEP(*(.rti_fn*)) KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .; __rt_init_end = .;
. = ALIGN(4); . = ALIGN(4);

View File

@ -28,8 +28,5 @@ objs = PrepareBuilding(env, RTT_ROOT)
if GetDepend('RT_USING_RTGUI'): if GetDepend('RT_USING_RTGUI'):
objs = objs + SConscript(RTT_ROOT + '/examples/gui/SConscript', variant_dir='build/examples/gui', duplicate=0) objs = objs + SConscript(RTT_ROOT + '/examples/gui/SConscript', variant_dir='build/examples/gui', duplicate=0)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -38,6 +38,12 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
. = ALIGN(4); . = ALIGN(4);
_etext = .; _etext = .;
} > CODE = 0 } > CODE = 0

View File

@ -25,8 +25,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False) objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -41,6 +41,12 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
} >CODE } >CODE
. = ALIGN(4); . = ALIGN(4);

View File

@ -25,8 +25,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False) objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -35,6 +35,12 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
. = ALIGN(4); . = ALIGN(4);
_etext = .; _etext = .;
} > CODE = 0 } > CODE = 0

View File

@ -28,8 +28,5 @@ objs = PrepareBuilding(env, RTT_ROOT)
if GetDepend('RT_USING_RTGUI'): if GetDepend('RT_USING_RTGUI'):
objs = objs + SConscript(RTT_ROOT + '/examples/gui/SConscript', variant_dir='build/examples/gui', duplicate=0) objs = objs + SConscript(RTT_ROOT + '/examples/gui/SConscript', variant_dir='build/examples/gui', duplicate=0)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -39,8 +39,5 @@ if GetDepend('RT_USING_RTGUI'):
# libc testsuite # libc testsuite
# objs = objs + SConscript(RTT_ROOT + '/examples/libc/SConscript', variant_dir='build/examples/libc', duplicate=0) # objs = objs + SConscript(RTT_ROOT + '/examples/libc/SConscript', variant_dir='build/examples/libc', duplicate=0)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -32,8 +32,5 @@ objs = PrepareBuilding(env, RTT_ROOT)
objs = objs + SConscript('CMSIS/SConscript', variant_dir='build/bsp/CMSIS', duplicate=0) objs = objs + SConscript('CMSIS/SConscript', variant_dir='build/bsp/CMSIS', duplicate=0)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -32,6 +32,12 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
. = ALIGN(4); . = ALIGN(4);
_etext = .; _etext = .;
} > CODE = 0 } > CODE = 0

View File

@ -30,8 +30,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT) objs = PrepareBuilding(env, RTT_ROOT)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -122,6 +122,13 @@ SECTIONS
KEEP(*(VSymTab)) KEEP(*(VSymTab))
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
} }
/* .ARM.exidx is sorted, so has to go in its own output section. */ /* .ARM.exidx is sorted, so has to go in its own output section. */
@ -151,6 +158,7 @@ SECTIONS
. = ALIGN (8); . = ALIGN (8);
_edata = .; _edata = .;
} >ram AT>rom } >ram AT>rom
.bss : .bss :
{ {
*(.shbss) *(.shbss)
@ -161,6 +169,7 @@ SECTIONS
_end = .; _end = .;
__end = .; __end = .;
} >ram AT>rom } >ram AT>rom
.heap : .heap :
{ {
*(.heap) *(.heap)

View File

@ -32,8 +32,5 @@ if GetDepend('RT_USING_RTGUI'):
# libc testsuite # libc testsuite
# objs = objs + SConscript(RTT_ROOT + '/examples/libc/SConscript', variant_dir='build/examples/libc', duplicate=0) # objs = objs + SConscript(RTT_ROOT + '/examples/libc/SConscript', variant_dir='build/examples/libc', duplicate=0)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -23,6 +23,12 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
/* section information for modules */ /* section information for modules */
. = ALIGN(4); . = ALIGN(4);
__rtmsymtab_start = .; __rtmsymtab_start = .;

View File

@ -25,8 +25,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT) objs = PrepareBuilding(env, RTT_ROOT)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -30,8 +30,5 @@ objs = PrepareBuilding(env, RTT_ROOT)
# kernel testsuite # kernel testsuite
#objs = objs + SConscript(RTT_ROOT + '/examples/kernel/SConscript', variant_dir='build/examples/kernel', duplicate=0) #objs = objs + SConscript(RTT_ROOT + '/examples/kernel/SConscript', variant_dir='build/examples/kernel', duplicate=0)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -26,6 +26,12 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
} > CODE = 0 } > CODE = 0
. = ALIGN(4); . = ALIGN(4);

View File

@ -30,8 +30,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False) objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -38,6 +38,13 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
/* section information for initial. */
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
. = ALIGN(4); . = ALIGN(4);
_etext = .; _etext = .;
} > CODE = 0 } > CODE = 0

View File

@ -39,6 +39,13 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
/* section information for initial. */
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
. = ALIGN(4); . = ALIGN(4);
_etext = .; _etext = .;
} > CODE = 0 } > CODE = 0

View File

@ -33,8 +33,5 @@ objs = PrepareBuilding(env, RTT_ROOT)
# STM32 firemare library building script # STM32 firemare library building script
objs = objs + SConscript( GetCurrentDir() + '/Libraries/SConscript', variant_dir='build/bsp/Libraries', duplicate=0) objs = objs + SConscript( GetCurrentDir() + '/Libraries/SConscript', variant_dir='build/bsp/Libraries', duplicate=0)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -39,6 +39,13 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
/* section information for initial. */
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
. = ALIGN(4); . = ALIGN(4);
_etext = .; _etext = .;
} > CODE = 0 } > CODE = 0

View File

@ -30,8 +30,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False) objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -39,6 +39,13 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
/* section information for initial. */
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
. = ALIGN(4); . = ALIGN(4);
_etext = .; _etext = .;
} > CODE = 0 } > CODE = 0

View File

@ -30,8 +30,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False) objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -39,6 +39,13 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
/* section information for initial. */
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
. = ALIGN(4); . = ALIGN(4);
_etext = .; _etext = .;
} > CODE = 0 } > CODE = 0

View File

@ -4,7 +4,7 @@ from building import *
cwd = GetCurrentDir() cwd = GetCurrentDir()
src = Glob('*.c') src = Glob('*.c')
CPPPATH = [cwd, Dir('#')] CPPPATH = [cwd, str(Dir('#'))]
group = DefineGroup('Applications', src, depend = [''], CPPPATH = CPPPATH) group = DefineGroup('Applications', src, depend = [''], CPPPATH = CPPPATH)

View File

@ -30,8 +30,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT) objs = PrepareBuilding(env, RTT_ROOT)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -25,8 +25,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT) objs = PrepareBuilding(env, RTT_ROOT)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -30,8 +30,5 @@ Export('rtconfig')
# prepare building environment # prepare building environment
objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False) objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
# build program # make a building
env.Program(TARGET, objs) DoBuilding(TARGET, objs)
# end building
EndBuilding(TARGET)

View File

@ -38,6 +38,12 @@ SECTIONS
__vsymtab_end = .; __vsymtab_end = .;
. = ALIGN(4); . = ALIGN(4);
. = ALIGN(4);
__rt_init_start = .;
KEEP(*(SORT(.rti_fn*)))
__rt_init_end = .;
. = ALIGN(4);
. = ALIGN(4); . = ALIGN(4);
_etext = .; _etext = .;
} > CODE = 0 } > CODE = 0