how to cross-compile LFS5.0 with nALFS?

vnevoa vasco.nevoa at iol.pt
Sun May 16 13:22:09 PDT 2004


Hello.
Anybody can explain how to configure for a cross compilation with 
nALFS-1.1.8 + LFS-5.0 Profile by Dave Wheeler?

My build system is an AthlonXP with Fedora Core 1, but the target system 
is a very old i486.

I changed the "gcc_target" in "config/general.ent" to 
"i486-pc-linux-gnu", and I thought I was doing well until i noticed that 
  the whole of Chapter 5 gets built into "/tools/i686-pc-linux-gnu/"... 
so when nALFS gets to the part of "Locking glibc", it fails because it 
is looking for "/tools/i486-pc-linux-gnu/"....

So, first question: is it possible to simply configure something and get 
this working? What?

Second: I have read the LFS hint on cross-compiling for the x86, and 
frankly, I don't like it. The whole "uname" hack is inelegant... as to 
the $CHOST variable, I've tried setting it to "i486-pc-linux-gnu" in the 
Chapter 5 files that establish environments, like binutils-pass1.xml, 
binutils-pass2.xml, gcc-pass1.xml, gcc-pass2.xml, and glibc.xml, but it 
didn't make any difference, I still get the "/tools/i686-pc-linux-gnu/" 
directory. Now the question: is there a clean and automated way to do 
this, or must I resort to the "uname" hack or set the CFLAGS and 
CXXFLAGS in almost every file??...

Thank you!

Vasco Nevoa.




More information about the alfs-discuss mailing list