xref: /netbsd-src/lib/libc/compat/gen/compat_time.c (revision fda5f877e5074e9afbf7381626cd3cf7f50a1165)
1*fda5f877Schristos /*	$NetBSD: compat_time.c,v 1.4 2013/10/04 21:07:37 christos Exp $	*/
2461a86f9Schristos 
3461a86f9Schristos /*
4461a86f9Schristos  * Written by Jason R. Thorpe <thorpej@NetBSD.org>, October 21, 1997.
5461a86f9Schristos  * Public domain.
6461a86f9Schristos  */
7461a86f9Schristos 
8461a86f9Schristos #include "namespace.h"
9461a86f9Schristos #include <sys/cdefs.h>
10461a86f9Schristos 
11461a86f9Schristos #define __LIBC12_SOURCE__
12461a86f9Schristos #include <time.h>
13461a86f9Schristos #include <sys/time.h>
14461a86f9Schristos #include <compat/include/time.h>
15461a86f9Schristos #include <compat/sys/time.h>
16461a86f9Schristos 
17461a86f9Schristos #ifdef __weak_alias
18461a86f9Schristos __weak_alias(time,_time)
19461a86f9Schristos #endif
20461a86f9Schristos 
21461a86f9Schristos __warn_references(time,
22461a86f9Schristos     "warning: reference to compatibility time();"
23461a86f9Schristos     " include <time.h> for correct reference")
24461a86f9Schristos 
25461a86f9Schristos #define timeval timeval50
26461a86f9Schristos #define time_t int32_t
27ca2d95d1Schristos 
28*fda5f877Schristos #define gettimeofday __compat_gettimeofday
29ca2d95d1Schristos 
30461a86f9Schristos #include "gen/time.c"
31