现象
在编译Debian时,报错,如下
P: Running debootstrap second stage under QEMU
W: Failure trying to run: /sbin/ldconfig
W: See //debootstrap/debootstrap.log for details
E: An unexpected failure occurred, exiting...
tar -jcf linaro-bullseye-alip-`date +%Y%m%d`-1.config.tar.bz2 auto/ config/ configure;
sudo mv chroot.files linaro-bullseye-alip-`date +%Y%m%d`-1.contents;
mv: cannot stat 'chroot.files': No such file or directory
Makefile:22: recipe for target 'all' failed
make: *** [all] Error 1
ERROR: Running build_debian failed!
ERROR: exit code 2 from line 1405:
RELEASE=$RK_DEBIAN_VERSION TARGET=desktop ARCH=$ARCH ./mk-base-debian.sh
原因
因为使用的是Ubuntu18
的版本,qemu
最高版本为2.11.1
,导致版本过低所以编译不过。
qemu-arm version 2.11.1(Debian 1:2.11+dfsg-1ubuntu7.41)
Copyright (c) 2003-2017 Fabrice Bellard and the QEMU Project developers
解决方法
把系统版本升级为20.04版本即可,这样版本就为4.2.1
,即可编译通过
~$ qemu-arm-static --version
qemu-arm version 4.2.1 (Debian 1:4.2-3ubuntu6.24)
Copyright (c) 2003-2019 Fabrice Bellard and the QEMU Project developers