diff options
author | Scott Wegner <swegner@hdfgroup.org> | 2008-02-18 14:05:47 (GMT) |
---|---|---|
committer | Scott Wegner <swegner@hdfgroup.org> | 2008-02-18 14:05:47 (GMT) |
commit | dee9447656a78e53342ec84eda9bd3a19be21920 (patch) | |
tree | 2ea5f5310d4415a775d71d8e5b1f5b1fb15613f5 | |
parent | 50a758f887ae8940ba78a469c47ae63979767b81 (diff) | |
download | hdf5-dee9447656a78e53342ec84eda9bd3a19be21920.zip hdf5-dee9447656a78e53342ec84eda9bd3a19be21920.tar.gz hdf5-dee9447656a78e53342ec84eda9bd3a19be21920.tar.bz2 |
[svn-r14595] Purpose: Patch the latest Cygwin's incompatibility with timzezone variable
Description:
We discovered that there was a problem with the latest cygwin DLL, in that it doesn't recognize the global variable 'timezone'. This is a problem on cygwin's side, not ours. Instead, we avoid the problem in configure with a case statement.
We didn't get this out in time for the release, but we can offer a patch instead.
Tested:
Cygwin on WinXP
All changes are in a cygwin 'case' clause, so shouldn't affect other platforms
-rwxr-xr-x | configure | 17 | ||||
-rw-r--r-- | configure.in | 22 |
2 files changed, 28 insertions, 11 deletions
@@ -45711,15 +45711,22 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: checking for global timezone variable" >&5 echo $ECHO_N "checking for global timezone variable... $ECHO_C" >&6; } -cat >conftest.$ac_ext <<_ACEOF + +case "`uname`" in + CYGWIN*) + { echo "$as_me:$LINENO: result: disabled in CYGWIN" >&5 +echo "${ECHO_T}disabled in CYGWIN" >&6; } + ;; + *) + cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -#include <sys/time.h> -#include <time.h> + #include <sys/time.h> + #include <time.h> #ifdef FC_DUMMY_MAIN #ifndef FC_DUMMY_MAIN_EQ_F77 # ifdef __cplusplus @@ -45759,7 +45766,7 @@ cat >>confdefs.h <<\_ACEOF #define HAVE_TIMEZONE 1 _ACEOF -{ echo "$as_me:$LINENO: result: yes" >&5 + { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } else echo "$as_me: failed program was:" >&5 @@ -45771,6 +45778,8 @@ fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext + ;; +esac { echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6; } diff --git a/configure.in b/configure.in index 2c45d38..7461c56 100644 --- a/configure.in +++ b/configure.in @@ -1728,13 +1728,21 @@ AC_MSG_RESULT([no])) dnl Check whether the global variable `timezone' is defined. AC_MSG_CHECKING([for global timezone variable]) -AC_TRY_LINK([ -#include <sys/time.h> -#include <time.h>], [timezone=0;], -AC_DEFINE([HAVE_TIMEZONE], [1], - [Define if `timezone' is a global variable]) -AC_MSG_RESULT([yes]), -AC_MSG_RESULT([no])) + +case "`uname`" in + CYGWIN*) + AC_MSG_RESULT([disabled in CYGWIN]) + ;; + *) + AC_TRY_LINK([ + #include <sys/time.h> + #include <time.h>], [timezone=0;], + AC_DEFINE([HAVE_TIMEZONE], [1], + [Define if `timezone' is a global variable]) + AC_MSG_RESULT([yes]), + AC_MSG_RESULT([no])) + ;; +esac dnl Check whether `struct timezone' is defined. AC_STRUCT_TIMEZONE |