public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Segmentation Fault(coredump) with g++ on SunOS 5.6
@ 1999-12-17 12:22 jimjackson
  1999-12-31 22:24 ` jimjackson
  2000-01-04  7:22 ` Herve Dutter
  0 siblings, 2 replies; 4+ messages in thread
From: jimjackson @ 1999-12-17 12:22 UTC (permalink / raw)
  To: help-gcc

Simple cout << "hello" type program fails with Segmentation Fault
(coredump). compiling with -static causes program to work properly.
Any ideas anyone?


Sent via Deja.com http://www.deja.com/
Before you buy.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Segmentation Fault(coredump) with g++ on SunOS 5.6
  1999-12-17 12:22 Segmentation Fault(coredump) with g++ on SunOS 5.6 jimjackson
@ 1999-12-31 22:24 ` jimjackson
  2000-01-04  7:22 ` Herve Dutter
  1 sibling, 0 replies; 4+ messages in thread
From: jimjackson @ 1999-12-31 22:24 UTC (permalink / raw)
  To: help-gcc

Simple cout << "hello" type program fails with Segmentation Fault
(coredump). compiling with -static causes program to work properly.
Any ideas anyone?


Sent via Deja.com http://www.deja.com/
Before you buy.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Segmentation Fault(coredump) with g++ on SunOS 5.6
  1999-12-17 12:22 Segmentation Fault(coredump) with g++ on SunOS 5.6 jimjackson
  1999-12-31 22:24 ` jimjackson
@ 2000-01-04  7:22 ` Herve Dutter
  2000-04-01  0:00   ` Herve Dutter
  1 sibling, 1 reply; 4+ messages in thread
From: Herve Dutter @ 2000-01-04  7:22 UTC (permalink / raw)
  To: help-gcc

The problem comes from an incompatibility between the iostreams
libraries. The SunWspro compiler used on SunOS 5.6 has a new - so called
strandard - implementation of the iostreams in a static library named
libCstd.a. The problem is that this implementation of the iostreams is
totally incompatible with the good old libiostreams.a used by everyone
else, including the g++ compiler.

If you compile a cout << "hello" code with g++ this will work until you
link the executable with a shared object library that was generated with
SunWspro and uses the new "Cstd" iostreams. In that case, your
executable will coredump even before reaching your main entry point.

If you can identify the shared object that causes the problem, you may
be able to get it re-generated either with g++ or with the
"-libraries=iostreams,no%Cstd" option for the SunWspro compiler.

Other possible solutions are:
- exclusive use of SunWspro on solaris,
- triple memory size and link everything static,
- throw Solaris to the bin and go Linux.

I still have to make my own choice as I have the same problem and the
shared object is a third party...

jimjackson@sungardebs.com wrote:
> 
> Simple cout << "hello" type program fails with Segmentation Fault
> (coredump). compiling with -static causes program to work properly.
> Any ideas anyone?
> 
> Sent via Deja.com http://www.deja.com/
> Before you buy.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Segmentation Fault(coredump) with g++ on SunOS 5.6
  2000-01-04  7:22 ` Herve Dutter
@ 2000-04-01  0:00   ` Herve Dutter
  0 siblings, 0 replies; 4+ messages in thread
From: Herve Dutter @ 2000-04-01  0:00 UTC (permalink / raw)
  To: help-gcc

The problem comes from an incompatibility between the iostreams
libraries. The SunWspro compiler used on SunOS 5.6 has a new - so called
strandard - implementation of the iostreams in a static library named
libCstd.a. The problem is that this implementation of the iostreams is
totally incompatible with the good old libiostreams.a used by everyone
else, including the g++ compiler.

If you compile a cout << "hello" code with g++ this will work until you
link the executable with a shared object library that was generated with
SunWspro and uses the new "Cstd" iostreams. In that case, your
executable will coredump even before reaching your main entry point.

If you can identify the shared object that causes the problem, you may
be able to get it re-generated either with g++ or with the
"-libraries=iostreams,no%Cstd" option for the SunWspro compiler.

Other possible solutions are:
- exclusive use of SunWspro on solaris,
- triple memory size and link everything static,
- throw Solaris to the bin and go Linux.

I still have to make my own choice as I have the same problem and the
shared object is a third party...

jimjackson@sungardebs.com wrote:
> 
> Simple cout << "hello" type program fails with Segmentation Fault
> (coredump). compiling with -static causes program to work properly.
> Any ideas anyone?
> 
> Sent via Deja.com http://www.deja.com/
> Before you buy.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2000-04-01  0:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-12-17 12:22 Segmentation Fault(coredump) with g++ on SunOS 5.6 jimjackson
1999-12-31 22:24 ` jimjackson
2000-01-04  7:22 ` Herve Dutter
2000-04-01  0:00   ` Herve Dutter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).