Error[Li005]: no definition for "__MCR", IAR tool linking error

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Error[Li005]: no definition for "__MCR", IAR tool linking error

5,405 Views
suhas_mv
Contributor II

Hello,

I am using  MCUXpresso SDK_2.2_MCIM6ULL and I am trying to build the file in IAR Embedded Workbench for ARM v8.30.2, as I am new to this tool I was trying with the demo code given in SDK_2.2_MCIM6ULL, when I try to Make the file the following errors were found. Can somebody help in letting me know the reason for the error.

IAR ELF Linker V8.30.2.160/W32 for ARM
Copyright 2007-2018 IAR Systems AB.
Error[Li005]: no definition for "__MCR" [referenced from C:\nxp\SDK_2.2_MCIM6ULL\boards\evkmcimx6ull\demo_apps\hello_world\iar\ddr_debug\obj\board.o]


Error[Li005]: no definition for "__MRC" [referenced from C:\nxp\SDK_2.2_MCIM6ULL\boards\evkmcimx6ull\demo_apps\hello_world\iar\ddr_debug\obj\board.o]


   8 072 bytes of readonly  code memory
   1 204 bytes of readwrite code memory
   1 944 bytes of readonly  data memory
  19 988 bytes of readwrite data memory
Errors: 2
Warnings: none
Link time:   0.09 (CPU)   0.09 (elapsed)
Error while running Linker
Total number of errors: 2
Total number of warnings: 0

Thanks,

SUHAS M V

0 Kudos
6 Replies

4,257 Views
任你行
Contributor I

找到问题了,

在... \devices\CMSIS\Include\core_ca7.h文件里加 #include "intrinsics.h"头文件就可以了

企业微信截图_16062725463453.png

0 Kudos

4,270 Views
任你行
Contributor I

Hello Suhas M V

我也遇到同样的问题,请问您解决了吗?是IAR版本的问题?

0 Kudos

4,422 Views
jlin
Contributor I

Add #include <instrinsics.h> to the files that have these errors.

4,422 Views
damonzhang
Contributor I

It does't work with IAR 8.*,The iar 7.80.4 working good

4,422 Views
suhas_mv
Contributor II
Hello damon zhang,
Thanks for the reply.
Regards,
Suhas M V

4,422 Views
jimmychan
NXP TechSupport
NXP TechSupport

Are you selecting the MCU in IAR is not correct?