This is the mail archive of the crossgcc@sources.redhat.com mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: installing a cross compiler


Jean-Christophe:


> I would install GCC as a cross-compiler but I have problems.

After reading the following, it sounds like you want a cross gcc that
runs on a Linux/386 host, and targets a solaris2.7 system.

> I'm building Gcc on a Red hat 7.1 system, Gcc (2.96 version) is
> already installed with the distribution and I would configure Gcc
> for solaris on the same computer.

Right.  The gcc 2.96 you are referring to is a "native" compiler.  It
produces executables for the host machine.

> First, I configure and build binutils :
>     configure --target=sparc-sun-solaris2.7 --prefix=/usr
>     make all install

This is probably ok, but I STRONGLY discourage your using /usr as your
prefix.  It's all too easy to screw things up when working as the root
user.  Instead, work as a normal user, and use a prefix that you have
permission to write to (a subdirectory of your home directory, for
example).

> Then, I configure Gcc (3.0.1 version) :
>     configure --target=sparc-sun-solaris2.7 --prefix=/usr
>     make all install

Nope, this won't work.  As your error messages indicate, you're
missing a lot of header files.  See the FAQ at
http://crossgcc.billgatliff.com instead.

Note that to complete the procedure, you'll probably need a runtime
library as well.  The FAQ is currently underdocumented where glibc is
concerned, but when my new Sun Blade workstation arrives (this week!),
I'll look into it.  Suggestions from others are welcome.


HTH,

b.g.
--
Bill Gatliff
bgat@billgatliff.com

------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sourceware.cygnus.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]