StartCore and C++ code -> linker erroro ""__exception_table_start__" is unresolved

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

StartCore and C++ code -> linker erroro ""__exception_table_start__" is unresolved

1,844件の閲覧回数
pawel_a
Contributor I
Hi,

I've created C++ code like below. But I cannot link it. I see linker error. Do I need link additional lib for this symbol?

-------------- LINK ERROR ---------------------------------------------
[LNK,2,6999,-1]: Error: "__exception_table_start__" is unresolved, referenced from:
        d:\fpdc_dsp\starcore\tools\compiler\lib\sc140\rtlib_be.elb(ExceptHandlerTSasm.eln)

[LNK,2,6999,-1]: Error: "__exception_table_end__" is unresolved, referenced from
:
        d:\fpdc_dsp\starcore\tools\compiler\lib\sc140\rtlib_be.elb(ExceptHandlerTSasm.eln)

-------------- CODE ---------------------------------------------
class A
{
       metod(){};
};


main()
{

A a[2];

    a[1].metod();
ラベル(1)
0 件の賞賛
返信
1 返信

634件の閲覧回数
CrasyCat
Specialist III
Hello
 
When you are building C++ code there are some additional predefined sections that you need to place in your linker command file and you need to define some linker symbols that he startup code will use to run properly..
The additional sections are: .staticinit, .exception and .exception_index.
The additional symbols are
_cpp_staticinit_start, _cpp_staticinit_end, , __exception_table_start__, , __exception_table_end__
 
Attached is a small example project for CodeWarrior StarCore V3.2.
Project is set up for SC140 simulator, but should show you how to activate/build C++ with StarCore build tools.
 
CrasyCat
Message Edited by t.dowe on 2009-09-04 11:03 AM
0 件の賞賛
返信