delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/03/17/03:42:07

Date: Tue, 17 Mar 1998 10:41:05 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: Jens Lehmann <Jens DOT Lehmann AT post DOT rwth-aachen DOT de>
cc: djgpp AT delorie DOT com
Subject: Re: SIGSEGV with "Hello World"
In-Reply-To: <350d9cb7.29045071@news.rwth-aachen.de>
Message-ID: <Pine.SUN.3.91.980317104048.17844I-100000@is>
MIME-Version: 1.0

On Mon, 16 Mar 1998, Jens Lehmann wrote:

> C:\Tmp>make hello
> gcc     hello.cc   -o hello

This wasn't supposed to link at all, as gcc wasn't instructed to
search the C++ class libraries.  You should say this instead:

       gcc hello.cc -o hello -lstdcxx -liostream

Please re-read the file `readme.1st' (available in the v2 directory
from the same place where you got DJGPP).  It explains in the
"Compilation" section how to compile and link C and C++ programs.

> C:\Tmp>hello
> Exiting due to signal SIGSEGV

Did you at some point install RSXNTDJ?  That is the only way I can
grasp what's happened to you.  RSX replaces the linker with a version
which doesn't fail when some library functions are missing (presumably
because they might be in some DLL supported by RSX), but when you run
programs which were linked this way, they crash at run time.  I advise
to unzip ld.exe from the Binutils again and use that.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019