diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2001-08-12 16:55:31 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2001-08-12 16:55:31 +0000 |
commit | 3d62afa2fe4f633de972ecfb12ef158a84f558f8 (patch) | |
tree | e2c789cae49238744a6762da01719d355c02ce4b /perl.h | |
parent | abae58a6d95251a1089732a25f3d20d450c8bef1 (diff) | |
download | perl-3d62afa2fe4f633de972ecfb12ef158a84f558f8.tar.gz |
On ithreads default to use_reentrant except on naturally
threadsafe platforms.
p4raw-id: //depot/perl@11645
Diffstat (limited to 'perl.h')
-rw-r--r-- | perl.h | 15 |
1 files changed, 13 insertions, 2 deletions
@@ -438,6 +438,19 @@ register struct op *Perl_op asm(stringify(OP_IN_REGISTER)); # endif #endif +/* Use the reentrant APIs like localtime_r and getpwent_r */ +#if defined(USE_THREADS) && defined(USE_ITHREADS) && !defined(USE_REENTRANT) +# define USE_REENTRANT +#endif + +/* Tru64/Digital UNIX/DEC OSF/1 and Win32 have naturally + * threadsafe libraries, no need to use any _r variants. */ +#ifdef USE_REENTRANT_API +# if (defined(__osf__) && defined(__alpha)) || defined(WIN32) +# undef USE_REEENTRANT_API +# endif +#endif + /* HP-UX 10.X CMA (Common Multithreaded Architecure) insists that pthread.h must be included before all other header files. */ @@ -4016,8 +4029,6 @@ extern void moncontrol(int); HAS_STRUCT_MSGHDR HAS_STRUCT_CMSGHDR - USE_REENTRANT_API - HAS_NL_LANGINFO so that Configure picks them up. */ |