Need help for porting
Mon Jan 12 15:05:00 GMT 2004
"Manmeet Singh Johar" <email@example.com> wrote:
> I forgot to mention 1 thing
> 1) The build system, which is used to do all the building. (would be
> RedHat Linux 7.2.)
> 2) The host system, which will eventually be used to run the cross
> compiler; in this case, Windows.
So you will first need a RedHat Linux 7.2 to Windows cross-toolchain
to produce Windows binaries on Linux...
The two most usual 'hosts' for "GCC for Windows" are Cygwin and MinGW.
Cygwin is some kind of Unix-emulation upon Windows and the runtime C
library resides in CYGWIN1.DLL, meanwhile MinGW is based on the 'native'
MS-C and MSVC DLLs, CRTDLL.DLL and MSVCRT.DLL runtime C libraries, ie.
the produced binutils, GCC, GDB, make etc. binaries use these DLLs.
For the MinGW target there should be downloadable prebuilt tools for
Linux, but one can just as well build a toolchain oneself. The MinGW
site, http://www.mingw.org, should tell more.
For the Cygwin target I don't know whether there are any downloadable
tools, although RedHat supporting Windows better than their own Linux
with the Cygwin target tools, sounds wacky.
> 3) The target system, for which we want to use our cross compiler to
> make executables; in this case, would be a third RISC processor.
First you must produce a Linux-hosted equivalent cross-toolchain. The
libraries for the target will be produced on the $build platform, so you
must have a toolchain for the target there. After that it is enough to
build only the binutils and GCC-only ('make all-gcc') for the target and
for the Windows host.
Isn't there any name for that RISC? The $target dependent problems are
$build and $host independent and talking about these usually happens very
freely, but maybe you have some reason to not mention it...
The Cygwin and MinGW $host related issues should be well-known. But they
may vary from time to time. I haven't built so many Cygwin hosted tools
on Linux (I have the same RedHat 7.x here) lately neither updated the
toolchain headers&libs from cygwin-1.3-something. Quite the same situation
is with MinGW. Anyhow I have built tens if not hundreds Windows-hosted
tools during the past years. I have currently near 100 different target
crosstools installed on my main Win2k system.
Whatever your $target is, it is possible that it already has some prebuilt
Windows-hosted tools as downloadable. Some common sites are:
http://www.ocdemon.com (ARM, PPC, MIPS,...)
http://www.kpit.com (SH, H8/300)
ftp://ftp.rtems.com/pub/gnucross (30 targets, at least for RedHat Linux)
Intel keeps tools for their XScale and StrongARM for free download and many
other chipmakers do the same for their chips. Anyhow one learns about cross-
GCCs when toying with them.
Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to firstname.lastname@example.org
More information about the crossgcc