|
之前没编译过linux,只编译安装过软件,今天试试编译lean的openwrt出现以下错误。- [ 2%] Building C object CMakeFiles/ubox.dir/blobmsg.c.o
- /home/tong/OP/lede/build_dir/hostpkg/libubox-2019-06-16-ecf56174/blobmsg.c: In function 'blobmsg_new':
- /home/tong/OP/lede/build_dir/hostpkg/libubox-2019-06-16-ecf56174/blobmsg.c:198:2: error: 'strcpy' offset 6 from the object at 'attr' is out of the bounds of referenced subobject 'name' with type 'uint8_t[]' {aka 'unsigned char[]'} at offset 6 [-Werror=array-bounds]
- 198 | strcpy((char *) hdr->name, (const char *)name);
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- In file included from /home/tong/OP/lede/build_dir/hostpkg/libubox-2019-06-16-ecf56174/blobmsg.c:16:
- /home/tong/OP/lede/build_dir/hostpkg/libubox-2019-06-16-ecf56174/blobmsg.h:42:10: note: subobject 'name' declared here
- 42 | uint8_t name[];
- | ^~~~
- cc1: all warnings being treated as errors
- make[6]: *** [CMakeFiles/ubox.dir/build.make:102: CMakeFiles/ubox.dir/blobmsg.c.o] Error 1
- make[6]: Leaving directory '/home/tong/OP/lede/build_dir/hostpkg/libubox-2019-06-16-ecf56174'
- make[5]: *** [CMakeFiles/Makefile2:259: CMakeFiles/ubox.dir/all] Error 2
- make[5]: Leaving directory '/home/tong/OP/lede/build_dir/hostpkg/libubox-2019-06-16-ecf56174'
- make[4]: *** [Makefile:130: all] Error 2
- make[4]: Leaving directory '/home/tong/OP/lede/build_dir/hostpkg/libubox-2019-06-16-ecf56174'
- make[3]: *** [Makefile:110: /home/tong/OP/lede/build_dir/hostpkg/libubox-2019-06-16-ecf56174/.built] Error 2
- make[3]: Leaving directory '/home/tong/OP/lede/package/libs/libubox'
- time: package/libs/libubox/host-compile#0.78#0.40#2.47
- make[2]: *** [package/Makefile:111: package/libs/libubox/host/compile] Error 2
- make[2]: Leaving directory '/home/tong/OP/lede'
- make[1]: *** [package/Makefile:107: /home/tong/OP/lede/staging_dir/target-x86_64_musl/stamp/.package_compile] Error 2
- make[1]: Leaving directory '/home/tong/OP/lede'
- make: *** [/home/tong/OP/lede/include/toplevel.mk:227:world] 错误 2
复制代码 环境manjaro AUR安装了OpenWrt-devel应该不是环境问题,看了会没看懂,求大佬解答。
|
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有账号?立即注册
×
|