www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/02/25/02:21:14

Date: Tue, 25 Feb 1997 09:15:20 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: Bryan Murphy <bryan AT alpha DOT hcst DOT com>
cc: djgpp AT delorie DOT com
Subject: Re: Problem Compiling C++ with DJGPP
In-Reply-To: <5esfme$ire@alpha.hcst.com>
Message-ID: <Pine.SUN.3.91.970225091234.6546B-100000@is>
MIME-Version: 1.0

On 24 Feb 1997, Bryan Murphy wrote:

> link them together, I get a ton of "Undefined Reference"
> errors.  These are all related to my procedures, and not
> the ones in teh C++ libraries (those I instaled).  What
> am I not getting right?  If I #include "prog.cc" all the
> .cc files into the main program, it compiles properly and
> the program runs, but it won't link if they are compiled
> as separate modules.
> 
> gcc test.cc inilib.cc llist.cc -lgpp -liostream

The above command seems to be OK (although you generally should also put
-lstdcxx at the end of the command line).  What you describe seems like 
some source-level problem, since the program links when it's on a single 
source file.  So I'd suggest to post the shortest program you can devise 
that exhibits the same problem.

- Raw text -


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