Cross compiling the X server?

Alexander Gottwald Alexander.Gottwald at s1999.tu-chemnitz.de
Fri Oct 15 13:34:26 PDT 2004


Kendall Bennett wrote:

> Hi Guys,
>
> Can someone point me at some resources and documentation explaing how to
> cross compile the X server? I need to cross compile a PowerPC version
> from my X86 box, but I am not sure the procedure needed to set up Imake
> so it will call the correct cross compiler and use the proper libs and
> headers.

In short (what I've done for the cygwin crosscompile):

compile binutils for cross compile (or install the binary package if it is
    available on your distribution)
compile gcc for cross compile
get libraries and header for host system

(brain dump: may be slightly incorrect. refer the binutils and gcc docu about
 cross compiling for exact syntax. The targetname ppc-gnu-linux may is a wild
 guess. Maybe this is different)
cd binutils
./configure --target ppc-gnu-linux
make
make install
cd ../gcc
./configure --target ppc-gnu-linux
make
make install

This will make and install binutils and gcc to /usr/ppc-gnu-linux/bin
Install the headers to /usr/ppc-gnu-linux/include and libraries to
/usr/ppp-gnu-linux/lib just like they would be aligned on the real system
in /usr/bin, /usr/lib or /usr/include

compiling Xorg is quite simple

make World CROSSCOMPILEDIR=/usr/ppc-gnu-linux/bin

my host.def also includes
#define UseInstalledOnCrossCompile YES

You may require freetype2 and expat compiled or add
#define HasFreetype2 NO
#define HasExpat NO
to host.def

If you still have questions feel free to contact me.

bye
        ago
NP: Die rzte - Dir
-- 
 Alexander.Gottwald at informatik.tu-chemnitz.de
 http://www.gotti.org           ICQ: 126018723



More information about the xorg mailing list