cpp project: "cannot find entry symbol Reset_Handler"

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

cpp project: "cannot find entry symbol Reset_Handler"

4,132件の閲覧回数
maximkhomutov
Contributor I

I am using Kinetis Design Studio 3.0.0 IDE. I made cpp project and try to build it. And I see the following message:

 

...kds_3.0.0/toolchain/bin/../lib/gcc/arm-none-eabi/4.8.4/../../../../arm-none-eabi/bin/ld.exe: warning: cannot find entry symbol Reset_Handler; defaulting to 00004400

 

My project has file startup.S with function Reset_Handler and with ISR vector table which use this function. I see that compiler created object file from my .S file and use it while try to link project.

The C project with the same startup.S file build fine and work.

 

What I am missing for cpp project?

 

BR,

Maxim

ラベル(1)
0 件の賞賛
返信
2 返答(返信)

2,747件の閲覧回数
BlackNight
NXP Employee
NXP Employee

It sounds like you have not used extern "C" for the header file declaration of Reset_Handler()?

Keep in mind that .c Files are compiled in C++ mode too.

An article related to that topic is here (written for an earlier version of KDS, but many things still apply):

C++ with Kinetis Design Studio | MCU on Eclipse

I hope this helps,

Erich

0 件の賞賛
返信

2,747件の閲覧回数
maximkhomutov
Contributor I

My Reset_Handler() is described in the same startup.S as ISR vector table which use this function. Where should I use extern "C"?

I made another experiment - removed Reset_Handler() from ISR table. And I got the same error!..

0 件の賞賛
返信