SDK 10.0.10.118
嗨,对话框的团队,
我正在尝试构建uartboot.bin和cli_programmer与新的闪存驱动器
但是它在构建uartboot项目时出现了这个错误。你能告诉我怎么修理吗?谢谢你!
--
使——沉默-k所有
构建文件:. . / src / c
调用:交叉ARM C编译器
/src/main.c:在函数'cmd_read_from_ram':
/src/main.c:787:49: error: taking address of packed member of 'struct cmdhdr_read_from_ram' may result in a unaligned pointer value [-Werror=address-of-packed-member]
778| translate_ram_addr((uint32_t *) &hdr->ptr);
| ^~~~~~~~~
../src/main.c:在函数'cmd_write_ram_to_qspi':
../src/main.c:814:49: error: taking address of packed member of 'struct cmdhdr_write_ram_to_qspi' may result in a unaligned pointer value [-Werror=address-of-packed-member]
814 | translate_ram_addr((uint32_t *) &hdr->ptr);
| ^~~~~~~~~
../src/main.c:在函数'cmd_execute_code':
../src/main.c:937:36: error: taking address of packed member of 'struct cmdhdr_execute_code' may result in a unaligned pointer value [-Werror=address-of-packed-member] /src/main.c:937:36: error: taking address of packed member of 'struct cmdhdr_execute_code' may result in a unaligned pointer value
937 | translate_ram_addr((uint32_t *) &hdr->addr);
| ^~~~~~~~~~~~~~~~~~~~~~~
/src/main.c: In function 'cmd_write_partition':
../src/main.c:1413:49: error: taking address of packed member of 'struct cmdhdr_write_partition' may result in a unaligned pointer value [-Werror=address-of-packed-member]
1413 | translate_ram_addr((uint32_t *) &hdr->ptr);
| ^~~~~~~~~
Cc1.exe:所有警告被视为错误
: * * * (src /子目录。可:20:src /主要。o]错误1
嗨jerryjuan,
谢谢你的在线问题。这听起来好像所有的警告都已经生成了错误。
为了避免这种情况,从“项目资源管理器”右键单击uartboot项目,然后导航到“属性”。然后,导航到正确的选项卡(见附件)并取消选择“生成错误而不是警告(Werrors)”复选框。
在我这边,我能够为发布版和调试版构建配置运行uartboot。此外,我使用的是最新版本的SS Studio,版本2.0.14.1748。
谢谢,PM_Dialog
谢谢,如果我在CFLAGS下面添加,它也可以工作