Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit cbcd8d7

Browse files
committed
Make more robust against Minix and Mac
1 parent 4de6cbc commit cbcd8d7

2 files changed

Lines changed: 22 additions & 5 deletions

File tree

Modules/timing.h

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,12 @@
3737
* Author: George V. Neville-Neil
3838
*
3939
* Update History: $Log$
40-
* Update History: Revision 2.1 1994/01/02 23:22:19 guido
41-
* Update History: Added George Neville-Neil's timing module
40+
* Update History: Revision 2.2 1994/01/14 16:55:47 guido
41+
* Update History: Make more robust against Minix and Mac
4242
* Update History:
43+
* Revision 2.1 1994/01/02 23:22:19 guido
44+
* Added George Neville-Neil's timing module
45+
*
4346
* Revision 1.1 93/12/28 13:14:19 gnn
4447
* Initial revision
4548
*
@@ -62,7 +65,16 @@
6265
#ifndef _TIMING_H_
6366
#define _TIMING_H_
6467

68+
#ifdef TIME_WITH_SYS_TIME
69+
#include <sys/time.h>
70+
#include <time.h>
71+
#else /* !TIME_WITH_SYS_TIME */
72+
#ifdef HAVE_SYS_TIME_H
6573
#include <sys/time.h>
74+
#else /* !HAVE_SYS_TIME_H */
75+
#include <time.h>
76+
#endif /* !HAVE_SYS_TIME_H */
77+
#endif /* !TIME_WITH_SYS_TIME */
6678

6779
static struct timeval aftertp, beforetp;
6880

Modules/timingmodule.c

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,12 @@
55
* Author: George V. Neville-Neil
66
*
77
* Update History: $Log$
8-
* Update History: Revision 2.1 1994/01/02 23:22:21 guido
9-
* Update History: Added George Neville-Neil's timing module
8+
* Update History: Revision 2.2 1994/01/14 16:55:50 guido
9+
* Update History: Make more robust against Minix and Mac
1010
* Update History:
11+
* Revision 2.1 1994/01/02 23:22:21 guido
12+
* Added George Neville-Neil's timing module
13+
*
1114
* Revision 1.1 93/12/28 13:14:39 gnn
1215
* Initial revision
1316
*
@@ -17,8 +20,10 @@
1720
*/
1821

1922
#ifndef lint
23+
#ifndef THINK_C
2024
static char rcsid [] = "$Header$" ;
21-
#endif
25+
#endif /* THINK_C */
26+
#endif /* lint */
2227

2328
#include "allobjects.h"
2429
#include "import.h"

0 commit comments

Comments
 (0)