| delorie.com/archives/browse.cgi | search |
| From: | "Alcer_Magnificus" <alcer AT post DOT pl> |
| Subject: | a newbie linking question |
| Newsgroups: | comp.os.msdos.djgpp |
| Message-ID: | <01befd4a$c1900140$0539a0d4@serwis> |
| X-Newsreader: | Microsoft Internet News 4.70.1155 |
| Lines: | 25 |
| Date: | Sun, 12 Sep 1999 18:24:00 GMT |
| NNTP-Posting-Host: | 212.160.57.5 |
| X-Complaints-To: | abuse AT tpsa DOT pl |
| X-Trace: | news.tpnet.pl 937160640 212.160.57.5 (Sun, 12 Sep 1999 20:24:00 MET DST) |
| NNTP-Posting-Date: | Sun, 12 Sep 1999 20:24:00 MET DST |
| Organization: | TPNET - http://www.tpnet.pl |
| To: | djgpp AT delorie DOT com |
| DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
| Reply-To: | djgpp AT delorie DOT com |
Hi, Im really a newbie, but I managed to read all the DJGPP docs at first. However, I cannot build any programs with this system. I wrote a simply 'Hello world' program at first. Then I compiled it using 'gcc -O2' and got no errors. The problem is while linking. I tried compile and link it: c:\>gcc -O2 -Wall hello.cc -o hello.exe -lm and I get some trash on my screen: c:\djgpp\tmp/ccIhNf16.o(.text+0x1f):hello.cc: undefined reference to 'cout' c:\djgpp\tmp/ccIhNf16.o(.text+0x24):hello.cc: undefined reference to 'ostream::operator<<(char const *)' c:\djgpp\tmp/ccIhNf16.o(.text+0x30):hello.cc: undefined reference to 'endl (ostream &)' that looks like a linker error. The c:\djgpp\tmp directory stays empty. But I did everything I managed to find in the manuals (BTW: I'm using Win95). Can anyone help me??? Anna, alcer AT post DOT pl
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |