summaryrefslogtreecommitdiff
path: root/m4/time_rz.m4
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2018-03-28 13:14:07 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2018-03-28 14:23:20 -0700
commite9bfd114a5e38842dd57929cc1afd1b3082a4c15 (patch)
treefc84887d589cc43cb3e5fc6396c7cb6f6e2a9f3c /m4/time_rz.m4
parentb61b3c804cb7c1348097ccef18d26fa4bdd37117 (diff)
downloademacs-e9bfd114a5e38842dd57929cc1afd1b3082a4c15.tar.gz
Update from Gnulib
This incorporates: 2018-03-28 time_rz: fix workaround for Mac OS X 10.6 infloop * m4/time_rz.m4: Copy from Gnulib.
Diffstat (limited to 'm4/time_rz.m4')
-rw-r--r--m4/time_rz.m49
1 files changed, 5 insertions, 4 deletions
diff --git a/m4/time_rz.m4 b/m4/time_rz.m4
index af9fa02b57d..55557062597 100644
--- a/m4/time_rz.m4
+++ b/m4/time_rz.m4
@@ -13,8 +13,8 @@ AC_DEFUN([gl_TIME_RZ],
AC_REQUIRE([gl_HEADER_TIME_H_DEFAULTS])
AC_REQUIRE([AC_STRUCT_TIMEZONE])
- # Mac OS X 10.6 loops forever with some time_t values less
- # than -67768038400665599. See Bug#27706, Bug#27736, and
+ # Mac OS X 10.6 loops forever with some time_t values.
+ # See Bug#27706, Bug#27736, and
# https://lists.gnu.org/r/bug-gnulib/2017-07/msg00142.html
AC_CACHE_CHECK([whether localtime loops forever near extrema],
[gl_cv_func_localtime_infloop_bug],
@@ -26,7 +26,7 @@ AC_DEFUN([gl_TIME_RZ],
#include <unistd.h>
#include <time.h>
]], [[
- time_t t = -67768038400665600;
+ time_t t = -67768038400666600;
struct tm *tm;
char *tz = getenv ("TZ");
if (! (tz && strcmp (tz, "QQQ0") == 0))
@@ -36,7 +36,8 @@ AC_DEFUN([gl_TIME_RZ],
/* Use TM and *TM to suppress over-optimization. */
return tm && tm->tm_isdst;
]])],
- [TZ=QQQ0 ./conftest$EXEEXT || gl_cv_func_localtime_infloop_bug=yes],
+ [(TZ=QQQ0 ./conftest$EXEEXT) >/dev/null 2>&1 ||
+ gl_cv_func_localtime_infloop_bug=yes],
[],
[gl_cv_func_localtime_infloop_bug="guessing no"])])
if test "$gl_cv_func_localtime_infloop_bug" = yes; then