mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2026-09-22 07:38:45 +08:00
2011-12-13 Ralf Corsépius <ralf.corsepius@rtems.org>
* configure.ac: Check for getrusage.h decl. * libcsupport/src/getrusage.c: Apply HAVE_DECL_GETRUSAGE (Missing prototypes).
This commit is contained in:
@@ -1,3 +1,9 @@
|
||||
2011-12-13 Ralf Corsépius <ralf.corsepius@rtems.org>
|
||||
|
||||
* configure.ac: Check for getrusage.h decl.
|
||||
* libcsupport/src/getrusage.c:
|
||||
Apply HAVE_DECL_GETRUSAGE (Missing prototypes).
|
||||
|
||||
2011-12-12 Sebastian Huber <sebastian.huber@embedded-brains.de>
|
||||
|
||||
* score/src/wkstringduplicate.c: New file.
|
||||
|
||||
@@ -98,6 +98,9 @@ RTEMS_CHECK_FUNC([pthread_attr_setguardsize],[#include <pthread.h>])
|
||||
RTEMS_CHECK_FUNC([pthread_attr_setstack],[#include <pthread.h>])
|
||||
RTEMS_CHECK_FUNC([pthread_attr_getstack],[#include <pthread.h>])
|
||||
|
||||
# Mandated by POSIX, not declared in some versions of newlib.
|
||||
AC_CHECK_DECLS([getrusage],,,[#include sys/resource.h])
|
||||
|
||||
# Newlib's unix/ directory
|
||||
AC_CHECK_FUNCS([ttyname getcwd])
|
||||
# </FIXME>
|
||||
|
||||
@@ -19,6 +19,10 @@
|
||||
#include <rtems.h>
|
||||
#include <rtems/seterr.h>
|
||||
|
||||
#if !HAVE_DECL_GETRUSAGE
|
||||
extern int getrusage(int who, struct rusage *usage);
|
||||
#endif
|
||||
|
||||
int getrusage(int who, struct rusage *usage)
|
||||
{
|
||||
struct timespec uptime;
|
||||
|
||||
Reference in New Issue
Block a user