Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexandre Oliva <aoliva@redhat.com>2001-01-26 00:40:28 +0300
committerAlexandre Oliva <aoliva@redhat.com>2001-01-26 00:40:28 +0300
commit610b895aa1cb734fd656c8fbb22c74eb97075bed (patch)
treec158c41f150a771269b76d5803a86d224cd22d06 /newlib/libc/sys
parent6bdf786b95e920ef4fdabc48f8f8f37abef82188 (diff)
* configure.host (sh*-*-*): Add -DHAVE_GETTIMEOFDAY to newlib_cflags.
* libc/sys/sh/syscalls.c (_gettimeofday): New.
Diffstat (limited to 'newlib/libc/sys')
-rw-r--r--newlib/libc/sys/sh/syscalls.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/newlib/libc/sys/sh/syscalls.c b/newlib/libc/sys/sh/syscalls.c
index 3626c0a44..f9761145f 100644
--- a/newlib/libc/sys/sh/syscalls.c
+++ b/newlib/libc/sys/sh/syscalls.c
@@ -1,6 +1,7 @@
#include <_ansi.h>
#include <sys/types.h>
#include <sys/stat.h>
+#include <sys/time.h>
#include "sys/syscall.h"
int errno;
@@ -174,3 +175,11 @@ _pipe (int *fd)
{
return __trap34 (SYS_pipe, fd);
}
+
+int
+_gettimeofday (struct timeval *tv, struct timezone *tz)
+{
+ tv->tv_usec = 0;
+ tv->tv_sec = __trap34 (SYS_time);
+ return 0;
+}