summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/mktime.c5
-rw-r--r--lib/strftime.c5
2 files changed, 10 insertions, 0 deletions
diff --git a/lib/mktime.c b/lib/mktime.c
index f759c29bb..952befe93 100644
--- a/lib/mktime.c
+++ b/lib/mktime.c
@@ -27,6 +27,11 @@
# include <config.h>
#endif
+/* Some systems need this in order to declare localtime_r properly. */
+#ifndef _REENTRANT
+# define _REENTRANT 1
+#endif
+
#ifdef _LIBC
# define HAVE_LIMITS_H 1
# define HAVE_LOCALTIME_R 1
diff --git a/lib/strftime.c b/lib/strftime.c
index b084851a4..5201a87e2 100644
--- a/lib/strftime.c
+++ b/lib/strftime.c
@@ -22,6 +22,11 @@
# include <config.h>
#endif
+/* Some systems need this in order to declare localtime_r properly. */
+#ifndef _REENTRANT
+# define _REENTRANT 1
+#endif
+
#ifdef _LIBC
# define HAVE_LIMITS_H 1
# define HAVE_MBLEN 1