2009-09-30 Ralf Corsépius <ralf.corsepius@rtems.org>

* libcsupport/src/__gettod.c: Rework autoconf defines.
	Eliminate RTEMS_UNIX.
This commit is contained in:
Ralf Corsepius
2009-09-30 06:45:38 +00:00
parent 7f9b08a19e
commit cc9b81ea45
2 changed files with 13 additions and 15 deletions
+2
View File
@@ -1,5 +1,7 @@
2009-09-30 Ralf Corsépius <ralf.corsepius@rtems.org>
* libcsupport/src/__gettod.c: Rework autoconf defines.
Eliminate RTEMS_UNIX.
* libcsupport/src/_calloc_r.c, libcsupport/src/_realloc_r.c:
Rework autoconf defines.
* libcsupport/src/open.c, libcsupport/src/close.c:
+11 -15
View File
@@ -17,22 +17,15 @@
#define __RTEMS_VIOLATE_KERNEL_VISIBILITY__
#if defined(RTEMS_NEWLIB)
#include <sys/time.h>
#include <errno.h>
#include <rtems.h>
#if !defined(RTEMS_UNIX)
#ifdef RTEMS_NEWLIB
#include <sys/reent.h>
#endif
#include <sys/time.h>
#include <time.h>
#include <errno.h>
#if defined(RTEMS_NEWLIB) && !defined(HAVE_GETTIMEOFDAY)
/*
* NOTE: The solaris gettimeofday does not have a second parameter.
*/
int gettimeofday(
struct timeval *tp,
void * __tz __attribute__((unused))
@@ -59,13 +52,15 @@ int gettimeofday(
return 0;
}
#endif
#if defined(RTEMS_NEWLIB)
#if defined(RTEMS_NEWLIB) && !defined(HAVE__GETTIMEOFDAY_R)
#include <sys/reent.h>
/*
* "Reentrant" version
*/
int _gettimeofday_r(
struct _reent *ignored_reentrancy_stuff __attribute__((unused)),
struct timeval *tp,
@@ -74,7 +69,9 @@ int _gettimeofday_r(
{
return gettimeofday( tp, tzp );
}
#endif
#if defined(RTEMS_NEWLIB) && !defined(HAVE__GETTIMEOFDAY)
/*
* "System call" version
*/
@@ -86,7 +83,6 @@ int _gettimeofday(
{
return gettimeofday( tp, tzp );
}
#endif
#endif /* defined(RTEMS_NEWLIB) */
#endif