ruby-changes:28607
From: kosaki <ko1@a...>
Date: Sun, 12 May 2013 17:40:59 +0900 (JST)
Subject: [ruby-changes:28607] kosaki:r40659 (trunk): * configure.in: adds comments for setjmp check.
kosaki 2013-05-12 17:40:47 +0900 (Sun, 12 May 2013) New Revision: 40659 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=40659 Log: * configure.in: adds comments for setjmp check. Modified files: trunk/ChangeLog trunk/configure.in Index: configure.in =================================================================== --- configure.in (revision 40658) +++ configure.in (revision 40659) @@ -1724,8 +1724,8 @@ else https://github.com/ruby/ruby/blob/trunk/configure.in#L1724 fi AC_CHECK_FUNCS(__syscall) -AC_CHECK_FUNCS(_longjmp) -AC_CHECK_FUNCS(_setjmp) +AC_CHECK_FUNCS(_longjmp) # used for AC_ARG_WITH(setjmp-type) +AC_CHECK_FUNCS(_setjmp) # used for AC_ARG_WITH(setjmp-type) AC_CHECK_FUNCS(chroot) AC_CHECK_FUNCS(chsize) AC_CHECK_FUNCS(clock_gettime) @@ -1836,13 +1836,6 @@ if test x"$ac_cv_func_clock_gettime" != https://github.com/ruby/ruby/blob/trunk/configure.in#L1836 AC_CHECK_FUNCS(clock_gettime) fi -AC_CACHE_CHECK(for sigsetjmp as a macro or function, ac_cv_func_sigsetjmp, - [AC_TRY_COMPILE([ -#include <setjmp.h> -], [sigjmp_buf env; sigsetjmp(env,1);], - ac_cv_func_sigsetjmp=yes, - ac_cv_func_sigsetjmp=no)]) - AC_CACHE_CHECK(for unsetenv returns a value, rb_cv_unsetenv_return_value, [AC_TRY_COMPILE([ #include <stdlib.h> @@ -1853,6 +1846,14 @@ if test "$rb_cv_unsetenv_return_value" = https://github.com/ruby/ruby/blob/trunk/configure.in#L1846 AC_DEFINE(VOID_UNSETENV) fi +# used for AC_ARG_WITH(setjmp-type) +AC_CACHE_CHECK(for sigsetjmp as a macro or function, ac_cv_func_sigsetjmp, + [AC_TRY_COMPILE([ +#include <setjmp.h> +], [sigjmp_buf env; sigsetjmp(env,1);], + ac_cv_func_sigsetjmp=yes, + ac_cv_func_sigsetjmp=no)]) + AC_CACHE_CHECK(for __builtin_setjmp, ac_cv_func___builtin_setjmp, [AC_TRY_LINK([@%:@include <setjmp.h> jmp_buf jb; void t(v) int v; {__builtin_longjmp(jb, v);}], @@ -1861,6 +1862,7 @@ AC_CACHE_CHECK(for __builtin_setjmp, ac_ https://github.com/ruby/ruby/blob/trunk/configure.in#L1862 [ac_cv_func___builtin_setjmp=no]) ]) +# we don't use _setjmp if _longjmp doesn't exist. test x$ac_cv_func__longjmp = xno && ac_cv_func__setjmp=no AC_MSG_CHECKING(for setjmp type) @@ -1896,6 +1898,7 @@ AC_MSG_RESULT(${setjmp_prefix}setjmp) https://github.com/ruby/ruby/blob/trunk/configure.in#L1898 AC_DEFINE_UNQUOTED([RUBY_SETJMP(env)], [${setjmp_prefix}setjmp(env${setjmp_sigmask+,0})]) AC_DEFINE_UNQUOTED([RUBY_LONGJMP(env,val)], [${setjmp_prefix}longjmp(env,val)]) AC_DEFINE_UNQUOTED(RUBY_JMP_BUF, ${setjmp_sigmask+${setjmp_prefix}}jmp_buf) +# End of setjmp check. AC_ARG_ENABLE(setreuid, AS_HELP_STRING([--enable-setreuid], [use setreuid()/setregid() according to need even if obsolete]), Index: ChangeLog =================================================================== --- ChangeLog (revision 40658) +++ ChangeLog (revision 40659) @@ -1,3 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Sun May 12 15:50:45 2013 KOSAKI Motohiro <kosaki.motohiro@g...> + + * configure.in: adds comments for setjmp check. + Sun May 12 15:38:09 2013 KOSAKI Motohiro <kosaki.motohiro@g...> * configure.in: move clock_gettime() check into regular place. -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/