HAVE_TIMEZONE and cygwin
Billinghurst, David (CRTS)
David.Billinghurst@riotinto.com
Wed May 1 21:21:00 GMT 2002
The cygwin patch for natSystem.cc
(http://gcc.gnu.org/ml/java-patches/2002-q2/msg00252.html)
probably should read something like
#elif HAVE_UNDERSCORE_TIMEZONE
tzoffset = _timezone;
#elif HAVE_TIMEZONE
// timezone is secs WEST of UTC.
tzoffset = timezone;
#else
// FIXME: there must be another global if neither
tm_gmtoff nor timezone
// is available, esp. if tzname is valid.
To do this we need to add to libjava/configure.in
a test something like
AC_TRY_COMPILE([#include <time.h>], [long z2 = _timezone;],
[AC_DEFINE(HAVE_UNDERSCORE_TIMEZONE)
AC_MSG_RESULT(yes)],
[AC_MSG_RESULT(no)])])
and preferably get the existing test
AC_TRY_COMPILE([#include <time.h>], [long z2 = timezone;],
[AC_DEFINE(HAVE_TIMEZONE)
AC_MSG_RESULT(yes)],
[AC_MSG_RESULT(no)])])
to fail for the cygwin <time.h> which has
char *_EXFUN(timezone, (void));
More information about the Java
mailing list