Re: Cross compilation of QEMU source code for ARM64
On Thu, 23 Mar 2023 at 19:57, Pedro Miguel Veiga de Almeida e Silva wrote: > > Hello, > > I am trying to cross compile the source code to deploy it in a xilinx ZCU106. > But every time I execute the ./configure --target-list=aarch64-softmmu > --enable-kvm and then make. > > But the file that compiles is a X86. --target-list specifies the target architecture, which to QEMU means the architecture the guest code runs. The architecture of the host (the machine QEMU runs on) is determined by what compiler you are building it with. If you run configure on an x86 machine and do not tell it "hey, you should build this with this cross compiler" then configure will just use 'gcc' and you will get x86 binaries. Typically you want to pass configure something like --cross-prefix=aarch64-linux-gnu- but this will only work if your host has the complete aarch64 cross-build environment set up, including the toolchain, pkg-config and all the necessary dependent libraries. thanks -- PMM
Re: Cross compilation of QEMU source code for ARM64
On 23/03/2023 19.30, Pedro Miguel Veiga de Almeida e Silva wrote: Hello, I am trying to cross compile the source code to deploy it in a xilinx ZCU106. But every time I execute the ./configure --target-list=aarch64-softmmu --enable-kvm and then make. But the file that compiles is a X86. Can you help me? With --target-list you select the target that QEMU emulates later, not the host environment. For cross-compiling, you need the --cross-prefix=... option of the configure script to set the prefix of your cross-compiler toolchain. For example, if your cross-compiler is called "arm-linux-gnueabi-gcc", you'd use: ./configure --cross-prefix=arm-linux-gnueabi- Hope that helps, Thomas
Cross compilation of QEMU source code for ARM64
Hello, I am trying to cross compile the source code to deploy it in a xilinx ZCU106. But every time I execute the ./configure --target-list=aarch64-softmmu --enable-kvm and then make. But the file that compiles is a X86. Can you help me?