CmBacktrace icon indicating copy to clipboard operation
CmBacktrace copied to clipboard

Keil 中使用 AC6 在链接时报错

Open bsbandwl opened this issue 3 years ago • 3 comments

STM32F765,使用 Keil AC6,编译没问题,链接时找不到 下图 图片

如果强行定义: #define __CLANG_ARM

可以链接成功,但是会提示下图 图片

希望得到帮助

bsbandwl avatar Mar 30 '22 12:03 bsbandwl

问题解决了 @armink 我把所有的 __CLANG_ARM 替换成 (defined(__ARMCC_VERSION) && (__ARMCC_VERSION >= 6120001)) 就好了 我查了一下,可能是我MDK版本问题,我是 5.35, AC6是 6.16, 手册写了,没有定义 __CLANG_ARM ,所以用不起来,我建议保险起见,不要使用 __CLANG_ARM

bsbandwl avatar Apr 01 '22 08:04 bsbandwl

这么坑呀

armink avatar Apr 01 '22 09:04 armink

确实是这个问题,我的是5.28也是没有 __CLANG_ARM 这个宏 修改在cmb_cfg.h文件里增加个宏 可以解决,不用替换 /* language of print information */ #define CMB_PRINT_LANGUAGE CMB_PRINT_LANGUAGE_ENGLISH

#ifndef __CLANG_ARM #define __CLANG_ARM (defined(__ARMCC_VERSION) && (__ARMCC_VERSION >= 6120001)) #endif

#endif /* CMB_CFG_H */

MS10755 avatar May 30 '22 07:05 MS10755