Article View: gnu.g++.help
Article #96Problem with ostream on SunOS4.1.2 with gcc2.2.2
From: Pete Meyer
Date: Sat, 08 Aug 1992 04:43
Date: Sat, 08 Aug 1992 04:43
20 lines
969 bytes
969 bytes
I've been writing bc++ on a PC until recently when gcc2.2.2 was installed
on our Sparcs. When I compile the following program I receive the error
message:
ld: Undefined symbol
__$_7ostream
collect: /usr/bin/ld returned 2 exit status
Is there some additional include file I am missing or is there some
other problem at work here?
#include <ostream.h>
main(){
FILE* file;
ostream out( file );
char fname[]="file.t2";
out.open( fname,output );
out << "Hello, World!\n";
out.close();
return 0;
}
Technical Details
Message-ID:
<1992Aug8.044350.29711@midway.uchicago.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!wupost!sdd.hp.com!usc!sol.ctr.columbia.edu!destroyer!ncar!uchinews!newsShow Full Headers
Complete Article Headers
Newsgroups: gnu.g++.help Path: arc1-ca.pugleaf.net!sparky!uunet!wupost!sdd.hp.com!usc!sol.ctr.columbia.edu!destroyer!ncar!uchinews!news From: meyer@galton.uchicago.edu (Pete Meyer) Subject: Problem with ostream on SunOS4.1.2 with gcc2.2.2 Message-ID: <1992Aug8.044350.29711@midway.uchicago.edu> Sender: news@uchinews.uchicago.edu (News System) Organization: Department of Statistics, University of Chicago Date: Sat, 8 Aug 1992 04:43:50 GMT Lines: 20