LT_INIT([disable-static])
])
+MC_TM_GMTOFF
+
AM_CONDITIONAL([RELEASE_BUILD], [test "$PACKAGE_VERSION" != "git"])
# Define full_libdir to be the fully expanded (${exec_prefix}, etc.)
--- /dev/null
+dnl Check for the tm_gmtoff field in struct tm
+dnl (Borrowed from the Gaim project)
+
+AC_DEFUN([MC_TM_GMTOFF],
+[AC_REQUIRE([AC_STRUCT_TM])dnl
+AC_CACHE_CHECK([for tm_gmtoff in struct tm], ac_cv_struct_tm_gmtoff,
+[AC_TRY_COMPILE([#include <sys/types.h>
+#include <$ac_cv_struct_tm>], [struct tm tm; tm.tm_gmtoff;],
+ ac_cv_struct_tm_gmtoff=yes, ac_cv_struct_tm_gmtoff=no)])
+if test "$ac_cv_struct_tm_gmtoff" = yes; then
+ AC_DEFINE(HAVE_TM_GMTOFF, 1, [tm_gmtoff is available.])
+fi
+])
minutes = tm->tm_min;
seconds = tm->tm_sec;
wday = tm->tm_wday;
+#ifdef HAVE_TM_GMTOFF
utc_offset = tm->tm_gmtoff;
+#else
+ utc_offset = 0;
+#endif
isSet = true;
}; //<! parses date from struct tm
tm.tm_hour = hours;
tm.tm_min = minutes;
tm.tm_sec = seconds;
+#ifdef HAVE_TM_GMTOFF
tm.tm_gmtoff = utc_offset;
+#endif
return mktime(&tm);
}; //<! returns this datetime as unixtime. will not work for dates before 1970/1/1 00:00:00 GMT
};