www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1995/03/01/16:15:05

From: Topi Ylinen <f1toyl AT uta DOT fi>
Subject: djgpp: problems with iostream.h
To: djgpp AT sun DOT soe DOT clarkson DOT edu
Date: Wed, 1 Mar 1995 22:27:29 +0200 (EET)

Both I and a friend of mine have had problems with djgpp's iostream library.
The FAQ provided no clues but the address of this list was given as the place
where one should look for help. If you answer this question, please do it
by replying to this message - don't send your answer to the list. I am not
a member and I will not see your answer if you do that. Of course, you could
send a message to the list telling everybody that you have answered me and
nobody else need bother. 

Thanks - !

The version of djgpp is the newest available (from ftp.sunet.se),
112 if I recall correctly. Installed precisely as instructed in 
readme.1st and readme.dj, with objective C and C++ addons. 

All right, now here's the problem: neither I or the friend I mentioned have
managed to get iostream work as it (should?) does for Unix  g++ or  BorlandC++.

For example, if you have a program that looks like this:

	#include <iostream.h>

	int main ()
		{
	/* Hopefully the brackets and the endl look right to you...
	  I'm workin on a non-standard terminal that shows them as
	  Scandinavian alphabets... */
			cout << "This is a test.\n";
			return 0;
		}

BorlandC++ and Unix g++ compile it just fine.

However, the very same program gives two error messages when I try to
compile it with djgpp I get two error messages:

	Undefined reference to 'cout'

and
	Undefined reference to 'ostream::operator<<(char const *)'

My friend had the same problem and neither of us found a way to get 
around this. Replacing iostream with stdio and using printf works fine,
but I'd really like to use iostream...  

A lot of thanks in advance to anyone who can help.

--
Topi Ylinen 

- Raw text -


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