From 0774989aed761ea261d9768215b5601e446d2d6a Mon Sep 17 00:00:00 2001 From: nobu Date: Wed, 19 Dec 2007 04:57:46 +0000 Subject: * configure.in (TIMEZONE_VOID): check whether timezone requires zero arguments. [ruby-dev:32631] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@14316 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ configure.in | 11 +++++++++++ 2 files changed, 16 insertions(+) diff --git a/ChangeLog b/ChangeLog index 54555a7bf9..9ebc5cf64b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Wed Dec 19 13:57:43 2007 Nobuyoshi Nakada + + * configure.in (TIMEZONE_VOID): check whether timezone requires zero + arguments. [ruby-dev:32631] + Wed Dec 19 12:01:42 2007 Nobuyoshi Nakada * parse.y (f_rest_arg): check if duplicated. [ruby-core:14140] diff --git a/configure.in b/configure.in index 516055176a..8502b523b5 100644 --- a/configure.in +++ b/configure.in @@ -595,6 +595,17 @@ RUBY_CHECK_VARTYPE(timezone, [#include ], [long int]) RUBY_CHECK_VARTYPE(altzone, [#include ], [long int]) if test "$rb_cv_var_timezone" = no; then AC_CHECK_FUNCS(timezone) + if test "$ ac_cv_func_timezone" = yes; then + AC_CACHE_CHECK([whether timezone requires zero arguments], rb_cv_func_timezone_void, + [AC_TRY_COMPILE([#include ], + [(void)timezone(0, 0);], + [rb_cv_func_timezone_void=no], + [rb_cv_func_timezone_void=yes])] + ) + if test $rb_cv_func_timezone_void = yes; then + AC_DEFINE(TIMEZONE_VOID) + fi + fi fi AC_CACHE_CHECK(for negative time_t for gmtime(3), rb_cv_negative_time_t, -- cgit v1.2.3