home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / lang / cplus / 12451 < prev    next >
Encoding:
Internet Message Format  |  1992-08-17  |  1.7 KB

  1. Path: sparky!uunet!cs.utexas.edu!qt.cs.utexas.edu!yale.edu!yale!gumby!destroyer!ncar!noao!arizona!naucse!jdc
  2. From: jdc@naucse.cse.nau.edu (John Campbell)
  3. Newsgroups: comp.lang.c++
  4. Subject: SunOS conflicts with g++
  5. Keywords: size_t, ptrdiff_t, flock
  6. Message-ID: <5421@naucse.cse.nau.edu>
  7. Date: 17 Aug 92 23:06:07 GMT
  8. Organization: Northern Arizona University, Flagstaff AZ
  9. Lines: 35
  10.  
  11.  
  12. Help,
  13.  
  14. I'm using g++ on a Sparc (SunOS 4.1.2) and find myself with three
  15. compile errors that I wonder about fixing:  
  16.        1) conflicting types for `size_t':
  17.        2) conflicting types for `ptrdiff_t'
  18.        3) warning: `flock' was declared `extern' and later `static'
  19.  
  20. It appears each of these is a conflict between files in g++-include and
  21.  /usr/include/sys:
  22.  
  23.    1) conflicting types for `size_t':
  24.       /usr/include/sys/stdtypes.h:typedef    int        size_t;
  25.       /usr/local/lib/g++-include/stddef.h:typedef unsigned long   size_t;
  26.  
  27.    2) conflicting types for `ptrdiff_t'
  28.       /usr/include/sys/stdtypes.h:typedef int        ptrdiff_t;
  29.       /usr/local/lib/g++-include/stddef.h:typedef long int        ptrdiff_t;
  30.  
  31.    3) warning: `flock' was declared `extern' and later `static'
  32.      /usr/include/sys/fcntlcom.h:struct flock {
  33.      /usr/local/lib/g++-include/std.h:int       flock(int, int);
  34.  
  35. Anyone have an "expert" opinion about what to do with these?  (I
  36. assume I want to change the g++-include files, but wonder if that's
  37. really safe?)  War stories?  Gotcha's I might find further down the
  38. line as I mix g++ with SunOS 4.1.2?
  39.  
  40. Also, I wouldn't expect this particular question to be in the
  41. FAQ, but I'm new to this group.  Would someone tell me where the
  42. FAQ is kept?
  43. -- 
  44.     John Campbell               jdc@naucse.cse.nau.edu
  45.                                     JDC@NAUVAX.UCC.NAU.EDU
  46.