Mail Archives: djgpp/1997/10/19/17:19:11
I've just started using DJGPP. I've gotten the c compiler to work but
I'm having trouble with C++. I've down loaded the files gpp2721b.zip ,
lgp271b.zip , and obc2721b.zip.
When I try to compile a basic "hello c++ world" program (your laugh
here) I get the errors: undefined reference to 'cout'
undefined reference to 'ostream::operator<<(char const *)'
This is what I type at the command line:
gcc hello.cpp
I've also tried changing the extension to '.cxx'. I read somthing about
using 'G++' at the command line, but I don't have that, I think I've
downloaded everything I'm suppose to. I've also tried using gxx and cpp
at the command prompt but the don't seem to do anything.
I don't think it's a programming mistake but here's the program
#include <iostream.h>
void main()
{
cout << "Hello C++ world";
}
I'd appreciate any help,
Brian
- Raw text -