CaptainJane 发表于 2021-9-6 18:48:32

QT5.12.2交叉编译

基于源码OK3399-linux-release/host/aarch64-buildroot-linux-gnu/sysroot路径下的库进行QT编译,添加新的QT模块,指定了sysroot为上述路径。
还是报错:
> aarch64-linux-gnu-g++ -Wl,-O1 -fuse-ld=gold -o verifyspec verifyspec.o   -L/home/forlinx3399/linux/sysroot/usr/lib/   
> /usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/bin/ld.gold:错误: cannot open /lib64/libc.so.6: 没有那个文件或目录
> /usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/bin/ld.gold:错误: cannot open /usr/lib64/libc_nonshared.a: 没有那个文件或目录
> /usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/bin/ld.gold:错误: cannot open /lib/ld-linux-aarch64.so.1: 没有那个文件或目录
> /usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/lib/../lib/Scrt1.o(.text+0x20): 错误: 对‘__libc_csu_init’未定义的引用
> /usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/lib/../lib/Scrt1.o(.text+0x24): 错误: 对‘__libc_csu_init’未定义的引用
> /usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/lib/../lib/Scrt1.o(.text+0x28): 错误: 对‘__libc_csu_fini’未定义的引用
> /usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/lib/../lib/Scrt1.o(.text+0x2c): 错误: 对‘__libc_csu_fini’未定义的引用
> /usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/lib/../lib/Scrt1.o(.text+0x30): 错误: 对‘__libc_start_main’未定义的引用
> /usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/lib/../lib/Scrt1.o(.text+0x34): 错误: 对‘abort’未定义的引用
> collect2: error: ld returned 1 exit status
> Makefile:68: recipe for target 'verifyspec' failed
> make: *** Error 1
Note: Also available for Linux: linux-clang linux-icc

ERROR: Cannot compile a minimal program. The toolchain or QMakeSpec is broken.

倔强的土坷垃 发表于 2021-9-7 15:13:05

编译应用用到的交叉编译器在/host/bin目录下。
页: [1]
查看完整版本: QT5.12.2交叉编译