cross build world on amd64 install on ppc
Marcel Moolenaar
xcllnt at mac.com
Sat Mar 14 14:33:08 PDT 2009
On Mar 14, 2009, at 1:40 PM, Andreas Tobler wrote:
> make -j4 buildlernel TARGET_ARCH=powerpc KERNCONF=GENERIC
> make installkernel TARGET_ARCH=powerpc KERNCONF=GENERIC DESTDIR=/tmp
>
> Now I'd like to do the same for 'buildworld'.
make buildworld TARGET_ARCH...
make installworld TARGET_ARCH... DESTDIR...
> I have taken the approach to nfs export the /usr/src and the /usr/
> obj from the amd64 to the powerpc machine.
You can NFS export DESTDIR and mount that on your powerpc
machine.
> First, is this possible to do a buildkernel/buildworld on an amd64
> for powerpc and then install it on powerpc?
Indirectly yes.
> Is the nfs approach dead wrong?
No, but there are gotchas. For one, a cross build uses
/usr/obj/${TARGET_ARCH} as the root of the object tree,
whereas a native build simply uses /usr/obj. This needs
to be compensated for.
Also, as part of a buildworld we build host tools. These
you need to build on your powerpc. One way is to do a
buildworld on your powerpc machine after doing it on your
amd64, making sure that the object tree is shared. This
should avoid rebuilding on your powerpc, while making
sure the prerequisites are dealt with.
> If it is possible to do a cross buildworld how do I install it on
> the ppc machine?
I think the easiest approach is to do an installworld on
your amd64 and mount that on your powerpc machine. You
can use rsync to sync your powerpc /. Alternatives are
tar, cp -R, etc...
It would be great if we can improve the process so that
you can build on machine X and install on machine Y, by
sharing usr and obj trees.
--
Marcel Moolenaar
xcllnt at mac.com
More information about the freebsd-ppc
mailing list