Vote count:
0
I am building an arm compiler on a linux machine, which will run on a windows machine.
My build script seems to run fine, I finish all steps and in the end have a compiler for the windows machine that works. The problem lies in the binutils executables.
Here's a condensed view of the builds binaries in the installation tree:
arm-unknown-eabi
arm-unknown-eabi/bin
* Contains arm-unknown-eabi-gcc.exe, arm-unknown-eabi-ar.exe etc
arm-unknown-eabi/arm-unknown-eabi
arm-unknown-eabi/arm-unknown-eabi/bin
* Contains ar.exe
All of the arm-unknown-eabi-ar.exe files work just fine on my windows machine. The problem is, arm-unknown-eabi-gcc is trying to call ar.exe while building. Normally this would not be an issue, and is actually preferred. However, when I run ar.exe, the following error pops up in windows:
Program: ar.exe' failed to run: The specified executable is not a vlaid application for this OS platform. At line:1 char:1
ar, which is a product of binutils does not want to run on windows. I went back to have a look at my configure script for binutils. Here are the options I pass:
BUILD=x86_64-linux-gnu
HOST=i686-w64-mingw32
TARGET=arm-unknown-eabi
CONFIG_OPTIONS=(
--host=${HOST}
--build=${BUILD}
--target=${TARGET}
--prefix=${TOOLSDIR}
--with-cpu=cortex-m4
--with-fpu=fpv4-sp-d16
--with-float=hard
--with-mode=thumb
--enable-interwork
--enable-multilib
--disable-werror
--disable-nls
--with-gnu-as
--with-gnu-ld
My next attempt, I tried building binutils again with only the host, build, target, and prefix specified. Same error.
I am using the mxe cross compiler to build windows applications. Like I said before, it seems to be working fine, because every other executable built such as gcc, collect2, etc work just fine on the windows PC.
So I am lost as to what to try next. Any ideas?
Binutils executables are failing to run in a canadian cross compilation
Aucun commentaire:
Enregistrer un commentaire