From: donut@azstarnet.com (Matthew Mueller)
Subject: iostreams won't work
24 Apr 1997 06:49:46 -0700
Approved: cygnus.gnu-win32@cygnus.com
Distribution: cygnus
Message-ID: <3.0.32.19970423205747.0069b274.cygnus.gnu-win32@pop.azstarnet.com>
Mime-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
X-Sender: donut@pop.azstarnet.com
X-Mailer: Windows Eudora Pro Version 3.0 (32)
Original-To: gnu-win32@cygnus.com
Original-Sender: owner-gnu-win32@cygnus.com

when I try to compile this program:

#include <iostream.h>
#include <stdio.h>
int main(void){
  cout << "hi.\n";
  getchar();
  cout << "bye.\n";
  return 0;
}


I get this error:

f:\prog\c32>gcc test.cpp
C:\WIN95\TEMP/cc0010001.o(.text+0x1a):test.cc: undefined reference to `cout'
C:\WIN95\TEMP/cc0010001.o(.text+0x1f):test.cc: undefined reference to
`ostream::
operator<<(char const *)'
C:\WIN95\TEMP/cc0010001.o(.text+0x60):test.cc: undefined reference to `cout'
C:\WIN95\TEMP/cc0010001.o(.text+0x65):test.cc: undefined reference to
`ostream::
operator<<(char const *)'


I have all the environment vars set as specified in the FAQ.  I have
successfully compiled several standard c program.
--
Matthew Mueller
donut@azstarnet.com
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".
