Date: Mon, 17 Jun 1996 07:55:07 +0200 (IST) From: Eli Zaretskii To: Quan Liang Cc: "'djgpp AT delorie DOT com'" Subject: Re: Help Beginning In-Reply-To: <01BB5BCF.21042BE0@nyc-ny12-15.ix.netcom.com> Message-Id: Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Sun, 16 Jun 1996, Quan Liang wrote: > I an new to DJGPP and C/C++ in general. I downloaded djgpp 2.0 but it > cannot compile my test examples. I don't know what's wrong, hope anybody > help. [snip] > out<<"test\n"; [snip] > > >gcc -v -o mf myfile.cc > > myfile.cc: In function `int main(...)': > myfile.cc:6: `out' undeclared (first use this function) > myfile.cc:6: (Each undeclared identifier is reported only once > myfile.cc:6: for each function it appears in.) You meant `cout', not `out', right? > C:\GNU\TMP>gcc -v myfile.cpp [snip] > myfile.cc(.text+0x1d): undefined reference to `cout' > myfile.cc(.text+0x22): undefined reference to `ostream::operator<<(char const *)' Use `gxx' instead of `gcc' to compile C++ programs. And please download v2/faq200b.zip from the same place you get DJGPP and read the DJGPP FAQ list before you post here. At least your second problem is explained there in so many words (section 8.7).