home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / os / os2 / programm / 7882 < prev    next >
Encoding:
Text File  |  1993-01-22  |  1.5 KB  |  56 lines

  1. Nntp-Posting-Host: sognsvann.ifi.uio.no
  2. Newsgroups: comp.os.os2.programmer
  3. Path: sparky!uunet!mcsun!sunic!aun.uninett.no!nuug!ifi.uio.no!jonso
  4. From: jonso@ifi.uio.no (Jon Martin Solaas)
  5. Subject: emx 08f problem using seekg in iostream.h
  6. Message-ID: <1993Jan22.092814.7669@ifi.uio.no>
  7. Organization: Dept. of Informatics, University of Oslo, Norway
  8. Date: Fri, 22 Jan 1993 09:28:14 GMT
  9. Lines: 44
  10. Originator: jonso@sognsvann.ifi.uio.no
  11.  
  12.  
  13.  
  14. I recently upgraded my EMX / Gnu C++ system  from
  15. version 08e / 2.2.2 to 08f / 2.3.3. I have noticed
  16. that the libraries have been rearranged.
  17.  
  18. My problem:
  19.  
  20.    Where did the seekg and seekp functions in
  21.    istream and ostream go?
  22.  
  23. Using the functions under version 08e / 2.2.2 works
  24. just fine, but using version 08f / 2.3.3 gives the
  25. following error(s) when linking (using .o-style object
  26. files and .a-style libraries):
  27.  
  28. ./ccc00096: Undefined symbol _seekg__8iostreamlQ23ios8seek_dir
  29.  referenced from text segment
  30.  
  31. (repeated for each occurence of a seekg-call) 
  32.  
  33. The source might look like this:
  34.  
  35. #include <iostream.h>
  36. #include <fstream.h>
  37.  
  38. main () {
  39.    fstream internalFile("diskFile", ios::in | ios::app);
  40.    internalFile.seekg(1,ios::beg);
  41.    // ...
  42. }
  43.  
  44. The functions are still present in iostream.h, so I guess
  45. this is a sort of library problem. Do I have to use some new
  46. -l option under version 08f to get the libs right? The
  47. example above was compiled with the -lgpp option, both under
  48. version 08e and 08f. The iostream examples in /emx/test seems
  49. to work fine under both versions.
  50.  
  51.  
  52. Jon Martin Solaas
  53. jonso@ifi.uio.no
  54.  
  55.  
  56.