Mike McDonald wrote:
> >Date: Fri, 26 Jan 2001 10:37:03 -0800
> >From: Pete Popov <email@example.com>
> >To: Mike McDonald <firstname.lastname@example.org>
> >Subject: Re: Cross compiling RPMs
> >To start with, you'll need a cross tool chain setup properly with the
> >headers and libraries. One option is
> >ftp.mvista.com:/pub/Area51/mips_fp_le. You can grab everything (the
> >entire root fs) or just the tools: binutils, gcc, kernel headers,
> >glibc. Others might have similar toolchains they can point you at.
> >Another option is native builds, which I personally don't like.
> I have a working tool chain that I use to cross compile a kernel
> with sources from. How do I convince rpm to use that chain?
Is that tool chain setup to compile userland apps? Can you cross compile
with a command such as "mips_fp_le-gcc -o hello hello.c" and get a
little endian mips binary that runs on your system?
If so, then you need to modify the .spec file for the given rpm to pick
up the right tool chain, ... and you'll probably need to add macro files
that rpm picks up so that you can do something like:
rpm -ba --target=xxxxx <spec file>
That's easier said than done. I wouldn't know how to do it myself --
someone else has done it for me here.