From a9405cc25305fbdccd97fd95a57d8f76c9eda0ac Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Tue, 6 Oct 2020 13:28:24 +0000 Subject: (cherry-pick): HAVE_TM_GMTOFF detection doesn't work if CFLAGS contains -Werror. Here's the fix. --- unix/configure | 2 +- unix/tcl.m4 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/unix/configure b/unix/configure index 7d40237..9dd612d 100755 --- a/unix/configure +++ b/unix/configure @@ -14030,7 +14030,7 @@ cat >>conftest.$ac_ext <<_ACEOF int main () { -struct tm tm; tm.tm_gmtoff; +struct tm tm; (void)tm.tm_gmtoff; ; return 0; } diff --git a/unix/tcl.m4 b/unix/tcl.m4 index 25a01ac..51ac8d9 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 @@ -2339,7 +2339,7 @@ AC_DEFUN([SC_TIME_HANDLER], [ fi AC_CACHE_CHECK([tm_gmtoff in struct tm], tcl_cv_member_tm_gmtoff, [ - AC_TRY_COMPILE([#include ], [struct tm tm; tm.tm_gmtoff;], + AC_TRY_COMPILE([#include ], [struct tm tm; (void)tm.tm_gmtoff;], tcl_cv_member_tm_gmtoff=yes, tcl_cv_member_tm_gmtoff=no)]) if test $tcl_cv_member_tm_gmtoff = yes ; then AC_DEFINE(HAVE_TM_GMTOFF, 1, [Should we use the tm_gmtoff field of struct tm?]) -- cgit v0.12