home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!dtix!darwin.sura.net!spool.mu.edu!sdd.hp.com!hpscit.sc.hp.com!hplextra!hpfcso!stroyan
- From: stroyan@hpfcso.FC.HP.COM (Mike Stroyan)
- Newsgroups: comp.sys.hp
- Subject: Re: Compiling a short C program with "cc - Aa"
- Message-ID: <7371509@hpfcso.FC.HP.COM>
- Date: 29 Dec 92 19:56:44 GMT
- References: <b2X=m-@engin.umich.edu>
- Organization: Hewlett-Packard, Fort Collins, CO, USA
- Lines: 15
-
- In comp.sys.hp, dtk@atl.hp.com (Dara T. Khani) writes:
-
- > One step forward, one step back :(
- > The routine getrusage is not provided in HP-UX. You can either write
- > your own routine or use ifdef to isolate the call and use alternate calls.
- > An HP-UX routine similar to getrusage is times(2).
-
- Of course, the code already has a "times" based implemenatation inside the
- "#ifdef hpux" test. As the original poster noted-
- > > The symbol "hpux" isn't defined if I use "cc -Aa".
-
- Instead, use the symbol "__hpux". The ANSI C standard doesn't allow predefined
- cpp symbols without the leading underscores.
-
- Mike Stroyan, mike_stroyan@fc.hp.com
-