is it possible to chroot into arm64 from amd64?

Jonathan Chen jonc at chen.org.nz
Fri Feb 16 01:22:10 UTC 2018


On 16 February 2018 at 14:00, tech-lists <tech-lists at zyxst.net> wrote:
> Hi,
>
> Is it possible to have on an amd64 system, a chrooted or jailed arm64
> environment? It's possible to cross-compile an arm6 environment on
> amd64 and then chroot into the arm6 environment - is the same possible
> for arm64? I can cross-compile arm64 like this:
>
> # SYSROOT=/crossbuild/arm64
> # cd /usr/src
> # make -j32 TARGET=arm64 TARGET_ARCH=aarch64 buildworld
> # make DESTDIR=$SYSROOT TARGET=arm64 TARGET_ARCH=aarch64 installworld
>
> # make DESTDIR=$SYSROOT TARGET=arm TARGET_ARCH=armv6 distribution
> # cp /usr/local/bin/qemu-aarch64-static $SYSROOT/sbin
>
> # /usr/sbin/binmiscctl add arm64 --interpreter
> "/usr/local/bin/qemu-aarch64" \
[...]

You've copied qemu-aarch64-static to $SYSROOT/sbin. binmiscctl(8)
should use /sbin/qemu-aarch64-static as its arm64 interpreter in the
arm64-chroot.

Cheers.
-- 
Jonathan Chen <jonc at chen.org.nz>


More information about the freebsd-virtualization mailing list