sparc64 built from jh branch

Jeremy Huntwork jhuntwork at linuxfromscratch.org
Thu Oct 11 17:39:35 PDT 2007


Hello,

Well today I finished a sparc64 build based on the jh branch. Has anyone 
else done a native build on sparc hardware adapted from recent LFS?

I'm hesitating adding in the necessary changes to the branch. When it 
comes down to it, the changes aren't that bad, but I just wanted to 
sound it off someone else first.

  * GCC need some compiler flags set for sparc64 - some packages will 
fail otherwise. -mcpu=ultrasparc -mtune=ultrasparc works for my 
processor. So, for chapter 5 and 6, set an environment variable of 
CC="gcc f-mcpu=ultrasparc -mtune=ultrasparc". Most packages pick that up 
from the environment with the configure stage. Some few need it passed 
to make, like 'make CC="$CC"' Programs that require adding a 'CC=' to 
the make command are (IIRC, my notes are at work):
   procps
   bzip2
   sysklogd
   sysvinit
   util-linux
   udev

* util-linux needs a patch in chapter 5 & 6, CLFS calls it a syscall 
patch. Trying to work it into a sed, but the changes CLFS made are a 
little extensive.
   CLFS also created a patch to add a missing header for swapon.c, 
needed in chapter 6: util-linux-2.12r-missing_header-1.patch. But this 
patch could be traded for a sed:
   sed -i '/stat.h/a\#include <fcntl.h>' mount/swapon.c

* kbd requires two seds for sparc architectures:
   sed -i '/kbdrate/s/period/rate/' src/kbdrate.c
   sed -i '/kbio.h/d' src/{kbdrate,setleds}.c


Anyway, that's it. All things considered, it's not that bad. Also, 
that's it for the hardware I have (currently) available to test with: 
x86, x86_64, sparc{,64}, and ppc.

--
JH



More information about the lfs-dev mailing list