[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Pnet-developers] building pnet using arm cross-compiler
From: |
Gopal V |
Subject: |
Re: [Pnet-developers] building pnet using arm cross-compiler |
Date: |
Thu, 15 Sep 2005 22:29:10 -0700 (PDT) |
> I'm attempting to build pnet 0.7.2 tarballs for an embedded arm target, using
> gcc on an x86 box set up to cross-compile for arm.
> The cross-compiler works fine (I've been able to build and run simple apps
> with it) but I'm having some difficulty building pnet.
> I haven't been able to find any howto's describing the process, although I
> do see statements that it runs on a variety of target platforms, including
> arm.
I was about to reply "Search the archives" when I realized that indexing of
that has been terribly broken. Even I am not able
to find the original mail Rhys had sent about this.
> I suppose that treecc can be built for x86, and pnetlib as well (since the
> bytecode should run on all platforms).
> But what about the configure for pnet itself? Simply setting the configure
> --target option doesn't seem to work, neither does overriding the CC and LD
> environment variables for the parts of the tree that need to be compiled for
> the target (ilrun and native libraries).
You need treecc and pnet built for x86 and then build pnet and pnetlib for the
target platforms. Pnetlib has one single C library
inside it - XsharpSupport, which is a wrapper around X11 libs. Ideally you
need pnet/treecc installed on your build box and then
continue to build pnet for the target machine - preferably building pnetlib
first.
You need a clean copy of pnet and need to do the following (from memory).
CC=arm-linux-gcc LD=arm-linux-ld AR=arm-linux-ar RANLIB=arm-linux-ranlib
./configure --build=arm-linux --host=i386 --prefix=/home/gopalv/pnet-arm
You *cannot* re-use your x86 builds with this - I've no idea where that screws
up, but it does :)
> Has anyone been successful with this? Any other gotchas regarding arm
> targets or cross-compiling in general that others are aware of?
Lots of people have done this -
http://handhelds.org/~krokas/
http://handhelds.org/~krokas/screenshots/port.30056.png
http://t3.dotgnu.info/code/Dotgnu_Simputer.avi
I don't remember any gotchas in there - except when doing out-of-tree builds.
I've fixed those recently in CVS.
Show up on irc.freenode.net#dotgnu if you need more hand-holding with this :)
Cheers,
Gopal