Generic build question

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

Generic build question

689件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by ECamino on Thu Mar 14 11:26:09 MST 2013
Hi,

I can build my project fine in debug. When I try to build in release, I get:

[LEFT]In function `malloc':[/LEFT]
alloc.c.text.malloc+0x78): undefined reference to `_sbrk'

I researched the error on CR site. It seems that to build the release, the setting under tool settings for Target has to be Redlib, Redlib, and Redlib (semihost), under MCU Linker.

But the debug version builds Redlib, Redlib, Redlib (none).
If host/semihost has to do with debugging support, then why does release not build with MCU Linker set to Redlib (none)?

I have not modified linker script.

EC
[SIZE=2][/SIZE]
0 件の賞賛
返信
1 返信

667件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by ex-kayoda on Fri Mar 15 02:13:03 MST 2013
Different libraries provide different functions, that's not reduced to debug functions :)

Redlib(nohost) is useful for memory- (malloc) and string (memcopy) functions ;)

Default library settings of your project are generated while Project Wizard is generating your project :)

So if you generate a LPCXpresso Semihosting project, it's using Redlib(semihost).

But that's just default setting. If you want another library, change it :eek:

See : http://www.support.code-red-tech.com/CodeRedWiki/LibraryVariants
0 件の賞賛
返信