www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1995/08/01/02:14:01

Date: Tue, 1 Aug 1995 08:25:46 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: chm94 <chm94 AT aber DOT ac DOT uk>
Cc: djgpp AT sun DOT soe DOT clarkson DOT edu, chm94 AT aber DOT ac DOT uk
Subject: Re: Problem with <iostream.h>, gcc msdos version

On Mon, 31 Jul 1995, chm94 wrote:

> D:\GNU-C\gcc try.cc
> try.cc(.text+0x16):undefined reference to `cout'
> try.cc(.text+0x1b):undefined reference to `ostream::operator<<(char const *)'

You should do this:

	gcc try.cc -lgpp

The C++ library isn't searched by the linker by default, you must tell it 
to do it explicitly.  This issue is explained in detail in the DJGPP FAQ 
list (available as faq102.zip from the same place you get DJGPP), section 
8.8.

- Raw text -


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