移植了h7-tool的daplink相关文件,编译很多报错:
比如:error: unknown type name '__forceinline’和typedef __packed
关于typedef __packed,参考方法三:如果之前使用typedef __packed struct定义,则替换成:__PACKED_STRUCT。
关于error: unknown type name '__forceinline’报错网上遇到的几个朋友基本都是带有RTOS的,自己的没有带RTOS,还是先把编译器版本降回到v5。
参考方法一、
不降版本的尝试方法:
CubeMx生成FreeRTOS代码在ARM compiler6版本下编译__forceinline (unknown type name ‘__forceinline‘)报错——全网最详细解决
方案
https://blog.csdn.net/shenzhou17/article/details/142183196
参考方法二、
keil使用freertos出现error: unknown type name ‘__forceinline’ note: expanded from macro‘portFORCE_INLINE
https://blog.csdn.net/2301_80165137/article/details/145326988
参考方法三、
AC6使用 attribute((at(x)))需要改用__attribute__((section(“name”)))实现
https://www.armbbs.cn/forum.php?mod=viewthread&tid=93202