473,466 Members | 1,451 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

How to install and call the sun compiler instead of GCC?

In all my previous C++ projects I used the gcc as compiler.

For some reasons I want to try out the Sun compiler instead.
How can I install and use this compiler instead?

Is the Sun C++ compiler pre-installed on Linux resp. Solaris?

How can I call him?

Pablo

Jun 27 '08 #1
11 3898
On May 17, 10:13 am, pcs...@yahoo.com (Pablo Suarez) wrote:
In all my previous C++ projects I used the gcc as compiler.

For some reasons I want to try out the Sun compiler instead.
How can I install and use this compiler instead?

Is the Sun C++ compiler pre-installed on Linux resp. Solaris?

How can I call him?

Pablo
I highly doubt that - sun compiler on a linux box. But the reverse is
possible - having both sun c++ and g++ compiler on the same sun box.
You may refer the compilers using the absolute path. For example, your
sun compiler could be at /usr/SUNWSpro/bin/CC and your g++ could be
at /usr/local/bin/g++. You may ask your admin to install g++ for you
in the sun box. In all the cases(atleast what i have seen), g++ could
be on any box(sun,aix..) but the reverse isn't possible.

Thanks,
Balaji.
Jun 27 '08 #2
What I want know is why do you like to try sun conpiler on a linux
system?
On May 17, 11:13*pm, pcs...@yahoo.com (Pablo Suarez) wrote:
In all my previous C++ projects I used the gcc as compiler.

For some reasons I want to try out the Sun compiler instead.
How can I install and use this compiler instead?

Is the Sun C++ compiler pre-installed on Linux resp. Solaris?

How can I call him?

Pablo
sun
Jun 27 '08 #3
HelloLinux wrote:
What I want know is why do you like to try sun conpiler on a linux
system?
Because it works? Some of us prefer the same tools on more than one
platform.

--
Ian Collins.
Jun 27 '08 #4
Pablo Suarez wrote:
In all my previous C++ projects I used the gcc as compiler.

For some reasons I want to try out the Sun compiler instead.
How can I install and use this compiler instead?
Try comp.unix.solaris.

Hint - run the installer.

--
Ian Collins.
Jun 27 '08 #5
On 17 mai, 17:13, pcs...@yahoo.com (Pablo Suarez) wrote:
In all my previous C++ projects I used the gcc as compiler.
For some reasons I want to try out the Sun compiler instead.
How can I install and use this compiler instead?
Is the Sun C++ compiler pre-installed on Linux resp. Solaris?
No C++ compilers are "pre-installed" under Solaris. As far as I
know, most Linux distributions do include a version of g++, but
none (again as far as I know) include Sun CC. For corporate
use, I'd contact Sun for the C++ compiler for both platforms.
(The product name is actually Sun Studio 12, and it includes C,
C++ and Fortran.) I think a free version is also available, but
I've not experimented with it. For g++ for Solaris, I find it
easy enough to build myself from the downloaded sources, but Sun
used to make precompiled versions available as well. (Sun also
has a version of gcc 4.2.0 available which will use the Sun
optimizer.)
How can I call him?
Under Solaris, you invoke g++ with the command "g++", and Sun
C++ with the command "CC". Provided your $PATH is set
correctly, of course. But you'll still need to look at the
docs; neither compiler is really usable with just the default
options, and you'll need to work out which options are best for
your situation.

--
James Kanze (GABI Software) email:ja*********@gmail.com
Conseils en informatique orientée objet/
Beratung in objektorientierter Datenverarbeitung
9 place Sémard, 78210 St.-Cyr-l'École, France, +33 (0)1 30 23 00 34
Jun 27 '08 #6
On 17 mai, 22:39, Ian Collins <ian-n...@hotmail.comwrote:
HelloLinux wrote:
What I want know is why do you like to try sun conpiler on a
linux system?
Because it works? Some of us prefer the same tools on more
than one platform.
Or multiple tools on each box. It's always useful to compile
your code with several different compilers, and test it in
several different environments.

At least on a Sparc, Sun optimizes better than gcc; it's quite
possible that this is true as well for a PC.

--
James Kanze (GABI Software) email:ja*********@gmail.com
Conseils en informatique orientée objet/
Beratung in objektorientierter Datenverarbeitung
9 place Sémard, 78210 St.-Cyr-l'École, France, +33 (0)1 30 23 00 34
Jun 27 '08 #7
James Kanze wrote:
On 17 mai, 17:13, pcs...@yahoo.com (Pablo Suarez) wrote:
>In all my previous C++ projects I used the gcc as compiler.
>For some reasons I want to try out the Sun compiler instead.
How can I install and use this compiler instead?
>Is the Sun C++ compiler pre-installed on Linux resp. Solaris?

No C++ compilers are "pre-installed" under Solaris.
gcc is.
For corporate
use, I'd contact Sun for the C++ compiler for both platforms.
(The product name is actually Sun Studio 12, and it includes C,
C++ and Fortran.) I think a free version is also available, but
I've not experimented with it.
There is only one version, the free one.

--
Ian Collins.
Jun 27 '08 #8
On May 18, 9:54 pm, Ian Collins <ian-n...@hotmail.comwrote:
James Kanze wrote:
On 17 mai, 17:13, pcs...@yahoo.com (Pablo Suarez) wrote:
In all my previous C++ projects I used the gcc as compiler.
For some reasons I want to try out the Sun compiler instead.
How can I install and use this compiler instead?
Is the Sun C++ compiler pre-installed on Linux resp. Solaris?
No C++ compilers are "pre-installed" under Solaris.
gcc is.
It didn't use to be:-).
For corporate
use, I'd contact Sun for the C++ compiler for both platforms.
(The product name is actually Sun Studio 12, and it includes C,
C++ and Fortran.) I think a free version is also available, but
I've not experimented with it.
There is only one version, the free one.
I'm sure you can pay for it as well. (I don't handle that end
of things here, so I don't know all the details. I do know that
there is a free version for Linux, but it doesn't work with
Linux 2.6, only Linux 2.4. Which doesn't say much for Linux'
maturity.)

--
James Kanze (GABI Software) email:ja*********@gmail.com
Conseils en informatique orientée objet/
Beratung in objektorientierter Datenverarbeitung
9 place Sémard, 78210 St.-Cyr-l'École, France, +33 (0)1 30 23 00 34
Jun 27 '08 #9
James Kanze wrote:
On May 18, 9:54 pm, Ian Collins <ian-n...@hotmail.comwrote:
>There is only one version, the free one.

I'm sure you can pay for it as well. (I don't handle that end
of things here, so I don't know all the details. I do know that
there is a free version for Linux, but it doesn't work with
Linux 2.6, only Linux 2.4. Which doesn't say much for Linux'
maturity.)
You can opt to pay for support, the product is free. I'm not aware of
any restriction to Linux 2.4.

--
Ian Collins.
Jun 27 '08 #10
"Pablo Suarez" <pc****@yahoo.comwrote in message
In all my previous C++ projects I used the gcc as compiler.

For some reasons I want to try out the Sun compiler instead.
How can I install and use this compiler instead?

Is the Sun C++ compiler pre-installed on Linux resp. Solaris?
Your question is off-topic on this newsgroup. You should try some platform
dedicated to your platform to ask the question.
How can I call him?
How do you call "him" :-)? Through a Makefile probably? If yes, then you
know where to put the change.

--
http://techytalk.googlepages.com
Jun 27 '08 #11
On May 19, 11:56 am, Ian Collins <ian-n...@hotmail.comwrote:
James Kanze wrote:
On May 18, 9:54 pm, Ian Collins <ian-n...@hotmail.comwrote:
There is only one version, the free one.
I'm sure you can pay for it as well. (I don't handle that end
of things here, so I don't know all the details. I do know that
there is a free version for Linux, but it doesn't work with
Linux 2.6, only Linux 2.4. Which doesn't say much for Linux'
maturity.)
You can opt to pay for support, the product is free. I'm not
aware of any restriction to Linux 2.4.
The compiler works fine under later versions. The 64 bit linker
won't load its dynamic libraries correctly, however, which means
that it won't run. And of course, there's not much point in
compiling code if you cannot link it. (The problem may be
limited to the 64 bit version, but I don't have any 32 bit
system around to test it on.)

--
James Kanze (GABI Software) email:ja*********@gmail.com
Conseils en informatique orientée objet/
Beratung in objektorientierter Datenverarbeitung
9 place Sémard, 78210 St.-Cyr-l'École, France, +33 (0)1 30 23 00 34
Jun 27 '08 #12

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: jtan325 | last post by:
hi, i am running Linux Ubuntu Hoary and am trying to build the Python numarray package, v. 1.3.2 by hand since ubuntu's repos won't be updated until breezy. i have python 2.4, and gcc 3.3.5 ...
0
by: Jim Phelps | last post by:
After having memory leak issues with Xerces-c 2.3.0 for Solaris 2.7 for CC 6.2 I have decided to update to at least 2.4. I have downloaded the binary tarball and have installed it on my...
23
by: Fabian Müller | last post by:
Hi all, my question is as follows: If have a class X and a class Y derived from X. Constructor of X is X(param1, param2) . Constructor of Y is Y(param1, ..., param4) .
8
by: trying_to_learn | last post by:
Why do we need to explicitly call the copy constructor and the operator = , for base class and member objects in composition? ....book says "You must explicitly call the GameBoard copy-constructor...
1
by: Peter Hartmann | last post by:
How do I influence the platform type during install? Could you look at this and tell me what I'm doing wrong? It's still using information from get_platform instead of using my preference. #...
8
by: ThomasR | last post by:
I understand that virtual methods on inherited objects are slower than non-virtual methods because of the indirection required to support the call. However, when looking at IL code produced by...
3
by: Jeremy S. | last post by:
On my dev machine (XP/Pro with VS.NET 2003) I have been developing a Windows Service and installing it on the local machine by opening the Visual Studio Command Prompt and then executing . Now I...
2
by: jai hanuman | last post by:
somebody please help me install VS .NET with asp.net on XP home edition. I installed cassini but the VS won't install asp.net - it says it needs IIS. i've heard cassini can be used instead of...
0
by: =?utf-8?Q?Poor=20Yorick?= | last post by:
Today I needed to install python from source on linux to a custom path. /usr/lib/libtk8.3.so existed, but I wanted python to link to /my/custom/path/lib/libtk8.4.so. I had LDFLAGS set: ...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.