Using strtok_r in MCUXpresso

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Using strtok_r in MCUXpresso

1,582 次查看
biafra
Senior Contributor I

Hi everyone,

I'm using MCUXpresso 10.1.1, I need to use the strotok_r function in my code, I include string.h header file, but I get the following error/warning:

warning: implicit declaration of function 'strtok_r' [-Wimplicit-function-declaration]

error: undefined reference to `strtok_r'

Which steps must I follow? Is there any reference to use this function in MCUXpresso?

Many thanks

Biafra

2 回复数

1,319 次查看
lpcxpresso_supp
NXP Employee
NXP Employee

Try using strtok() instead. Otherwise if you really need strtok_r(), then try using Newlib rather than the default Redlib C library. For more background information on C library support in MCUXpresso IDE, see the MCUXpresso IDE v10.1 User Guide, chapter 13, "C/C++ Library Support".

Regards,

MCUXpresso IDE Support

1,319 次查看
biafra
Senior Contributor I

I will try your suggestion.

Many thanks

Biafra