www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/1997/12/14/05:16:51

Date: Sun, 14 Dec 1997 12:14:36 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: DJ Delorie <dj AT delorie DOT com>
cc: djgpp-workers AT delorie DOT com
Subject: Trouble with C++ and interrupt (fwd)
Message-ID: <Pine.SUN.3.91.971214121233.20351D-100000@is>
MIME-Version: 1.0

DJ, is there any magic we could put into lib/specs so that gcc would
automagically scan libstdcxx and libiostream for C++ programs (.cc, .cpp,
.cxx files)?  I'm sick and tired of threads like this. 

---------- Forwarded message ----------
Date: Thu, 11 Dec 1997 19:49:02 +0100
From: Thomas Larsson <thomas DOT larsson AT mbox5 DOT swipnet DOT se>
To: djgpp AT delorie DOT com
Newgroups: comp.os.msdos.djgpp
Subject: Trouble with C++ and interrupt

Hi

I have some problems when I try to compile C++ programs.

I just tried to compile the following file:
test.cpp:
#include <iostream.h>

void main(void)
{
	cout << "HI!";
}

I wrote "gcc test.cpp -o test.exe"
I got two strange error messages:
c:/djgpp/tmp\ccdaaaaa(.text+0x12):test.cc: undefined reference to 'cout'
c:/djgpp/tmp\ccdaaaaa(.text+0x17):test.cc: undefined reference to
'ostream::operator(((char const*)'

What could be wrong?
(I've tried to compile the examples in the help files but they don't
work either. I can compile C programs without problems)

I have also tried to compile some examples for multiple keypresses. They
all include a keyword called "interrupt" but DJGPP doesn't find it
anywhere. Should I replace it or should I use another keyword?

Thanks for your help, I have looked through the FAQ but I can't find any
answers to the problems there...

Regards Thomas

- Raw text -


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