times.h
上传用户:luoyougen
上传日期:2008-05-12
资源大小:23136k
文件大小:2k
源码类别:

VxWorks

开发平台:

C/C++

  1. /* times.h - UNIX-style timeval structure defenition */
  2. /* Copyright 1984-1992 Wind River Systems, Inc. */
  3. /*
  4. modification history
  5. --------------------
  6. 02d,22sep92,rrr  added support for c++
  7. 02c,19aug92,smb  moved from systime.h
  8. 02b,31jul92,gae  changed INCtimeh to INCsystimeh.
  9. 02a,04jul92,jcf  cleaned up.
  10. 01g,26may92,rrr  the tree shuffle
  11. 01f,04oct91,rrr  passed through the ansification filter
  12.   -fixed #else and #endif
  13.   -changed copyright notice
  14. 01e,10jun91.del  added pragma for gnu960 alignment.
  15. 01d,25oct90,dnw  changed name from utime.h to systime.h.
  16.  added test for SunOS headers already included.
  17. 01c,05oct90,shl  added copyright notice.
  18. 01b,04nov87,dnw  removed unnecessary stuff.
  19. 01a,15oct87,rdc  written
  20. */
  21. #ifndef __INCtimesh
  22. #define __INCtimesh
  23. #ifdef __cplusplus
  24. extern "C" {
  25. #endif
  26. #if ((CPU_FAMILY==I960) && (defined __GNUC__))
  27. #pragma align 1 /* tell gcc960 not to optimize alignments */
  28. #endif /* CPU_FAMILY==I960 */
  29. /* the following conditional is to avoid conflict with SunOS header <sys/time.h>
  30.  * (_TIME_ is used in SunOS 4.0.3 and _sys_time_h is used in 4.1)
  31.  */
  32. #if !defined(_TIME_) && !defined(_sys_time_h)
  33. struct timeval
  34.     {
  35.     long tv_sec; /* seconds */
  36.     long tv_usec; /* microseconds */
  37.     };
  38. struct timezone
  39.     {
  40.     int tz_minuteswest; /* minutes west of Greenwich */
  41.     int tz_dsttime; /* type of dst correction */
  42.     };
  43. #endif /* !_TIME_ && !_sys_time_h */
  44. #if ((CPU_FAMILY==I960) && (defined __GNUC__))
  45. #pragma align 0 /* turn off alignment requirement */
  46. #endif /* CPU_FAMILY==I960 */
  47. #ifdef __cplusplus
  48. }
  49. #endif
  50. #endif /* __INCtimesh */