newlib/.../getreent.c: Allow to be provided by host and do so for RTEMS

RTEMS provides the option to have a global or per-thread reentrancy
as part of application configuration. As part of this, RTEMS provides
the implementation of __getreent() as appropriate. Allow the target
to determine if this method is present in libc.a.
This commit is contained in:
Joel Sherrill
2017-10-11 07:57:44 -05:00
committed by Corinna Vinschen
parent 181fe5d2ed
commit b1a388799d
2 changed files with 10 additions and 2 deletions

View File

@ -1,5 +1,11 @@
/* default reentrant pointer when multithread enabled */
#ifdef GETREENT_PROVIDED
int _dummy_getreent;
#else
#include <_ansi.h>
#include <reent.h>
@ -12,3 +18,5 @@ _DEFUN_VOID(__getreent)
{
return _impure_ptr;
}
#endif