Most systems don't guard the C reentrant functions but on HP-UX 11
they are not declared
unless _REENTRANT is defined. This causes problems for configure, etc.
The attached change adds the _REENTRANT define when _HPUX_SOURCE is
defined.
A similar change was applied to HP-UX 10 three years ago.
This resolves PR libfortran/63471.
Tested on hppa2.0w-hp-hpux11.11. Committed to trunk.
Dave
--
John David Anglin dave.ang...@bell.net
2014-01-13 John David Anglin <dave.ang...@nrc-cnrc.gc.ca>
PR libfortran/63471
* config/pa/pa-hpux11.h (TARGET_OS_CPP_BUILTINS): Define _REENTRANT
when _HPUX_SOURCE is defined.
Index: config/pa/pa-hpux11.h
===================================================================
--- config/pa/pa-hpux11.h (revision 216000)
+++ config/pa/pa-hpux11.h (working copy)
@@ -40,6 +40,7 @@
if (c_dialect_cxx ()) \
{ \
builtin_define ("_HPUX_SOURCE"); \
+ builtin_define ("_REENTRANT"); \
builtin_define ("_INCLUDE_LONGLONG"); \
builtin_define ("__STDCPP__"); \
} \
@@ -48,6 +49,7 @@
if (!flag_iso) \
{ \
builtin_define ("_HPUX_SOURCE"); \
+ builtin_define ("_REENTRANT"); \
if (preprocessing_trad_p ()) \
{ \
builtin_define ("hp9000s800"); \