home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!mcsun!sunic!isgate!krafla!jond
- From: jond@rhi.hi.is (Jon Danielsson)
- Newsgroups: comp.sys.hp
- Subject: CC (8.07) does not like math.h and stdlib.h together
- Summary: C++ programs wich include math.h and stdlib.h don't compile under 8.07
- Keywords: CC
- Message-ID: <5255@krafla.rhi.hi.is>
- Date: 28 Aug 92 13:58:51 GMT
- Sender: usenet@rhi.hi.is
- Lines: 34
-
- I have c++ programs which include math.h and stdlib.h, which work
- fine with the header files I got with the 8.05 system. When I got the
- upgrate to 8.07 I find that I cannot compile such programs because
- (apparently) there are inline definitions of the abs function in
- both files. Is there any way to get this to work without having to
- edit the header files I got with the system?
- An example of this follows:
-
- // program x.cc
- #include <stdlib.h>
- #include <math.h>
- void main(void) { }
-
- menger:/users/walras/jond[3809] > CC x.cc
- CC: "/usr/include/math.h", line 185: error: two definitions of abs() (1034)
-
-
- jondan
- __________________________________________________________________
- Jon Danielsson | 2 + 2 = 3, for suitably
- Department of Economics | small values of 2
- University of Iceland |
- 101 Reykjavik |
- Iceland |
- tel: 354 1 694572 |
- fax: 354 1 26806 |
- E-mail jond@rhi.hi.is |
- __________________________________________________________________
-
- --
- __________________________________________________________________
- Jon Danielsson | 2 + 2 = 3, for suitably
- Department of Economics | small values of 2
- University of Iceland |
-