The UNIX Forums
"Join the Network of UNIX System Users"


 
Subject: c compiler to build sparc/solaris binaries on linux
combat
Newbie
Rank: 1



UID 93
Digest Posts 0
Credits 0
Posts 71
Reading Access 10
Registered Apr 25, 2007
Status Offline
Post at Jun 2, 2007 10:27 AM  Profile | P.M. 
c compiler to build sparc/solaris binaries on linux



c compiler to build sparc/solaris binaries on linux




just that the subject says.

i am looking for a c compiler for linux x86 that will allow me to compile a c source code file and the resulting binary will be able to run on a sparc running solaris.


Top
anbu23
Newbie
Rank: 1



UID 4
Digest Posts 0
Credits 0
Posts 13
Reading Access 10
Registered Apr 25, 2007
Status Offline
Post at Jun 2, 2007 10:27 AM  Profile | P.M. 
this is what's known as cross-compilation, and it's not that simple. gcc can be configured to cross-compile, yes, but that's not usually installed as standard, it's not as easy as "add sparc module", and there's more to it than the compiler. you need the solaris headers and libraries, too -- after all you're compiling for sparc/solaris, not sparc/gnu. even if you do get a working sparc compiler on x86, you could be plagued with weird issues. you wouldn't even have a way to test your executables.

my suggestion would be to just get a sparc on ebay.
Top
flyingdagger
Newbie
Rank: 1



UID 147
Digest Posts 0
Credits 0
Posts 23
Reading Access 10
Registered Apr 25, 2007
Status Offline
Post at Jun 2, 2007 10:27 AM  Profile | P.M. 
quote:
originally posted by corona688
this is what's known as cross-compilation, and it's not that simple. gcc can be configured to cross-compile, yes, but that's not usually installed as standard, it's not as easy as "add sparc module", and there's more to it than the compiler. you need the solaris headers and libraries, too -- after all you're compiling for sparc/solaris, not sparc/gnu. even if you do get a working sparc compiler on x86, you could be plagued with weird issues. you wouldn't even have a way to test your executables.

my suggestion would be to just get a sparc on ebay.



i would second everything corona688 has said here, you can pick up an ultra 5 or 10 on ebay for peanuts these days, and would be a more worthwhile invesment than the time it would take to get the cross compile working.
Top
 

 

All times are GMT, the time now is Jul 31, 2010 03:33 AM

Powered by Discuz! 5.0.0  © 2001-2006 UNIX Forums
Processed in 0.005186 second(s), 8 queries

Clear Cookies - Contact Us - UNIX Help - Archiver - WAP