Cross build script issue

Feng Xuan fengxuan@hotmail.com
Wed Apr 11 10:18:00 GMT 2018
Please ignore my last email.


I put in a typo, --host=blahblah should be --target=blahblah, code has no issue.


Sorry,

Feng

________________________________
From: Feng Xuan <fengxuan@hotmail.com>
Sent: April 11, 2018 6:06 AM
To: binutils@sourceware.org
Subject: Cross build script issue


Good morning guys!


When I tried to make a cross build like this:


CC=x86_64-pass1-linux-gnu-gcc ../configure --prefix=/home/feng/.local/tools --host=x86_64-pass2-linux-gnu --disable-nls --disable-werror --with-lib-path=/home/feng/.local/tools/lib --with-sysroot

I got below error:

make[3]: Entering directory '/home/feng/Downloads/binutils-2.30/build/bfd/doc'
gcc -o chw$$  \
    -I.. -I../../../bfd/doc/.. -I../../../bfd/doc/../../include -I../../../bfd/doc/../../intl -I../../intl ../../../bfd/doc/chew.c; \
/bin/bash ../../../bfd/doc/../../move-if-change \
  chw$$ chew; \
touch chew.stamp
../../../bfd/doc/chew.c:85:20: fatal error: assert.h: No such file or directory
compilation terminated.
mv: cannot stat 'chw28512': No such file or directory

It seems the Makefile still calls native gcc, I don't even have a native gcc at the moment, should it use x86_64-pass1-linux-gnu-gcc instead?

To work around, I can create a soft gcc link pointing to x86_64-pass1-linux-gnu-gcc, but clean code would be better.

Thanks,
Feng




More information about the Binutils mailing list