From 1fa5d76ae08d000b8ba9b728b78e5a9d3d308129 Mon Sep 17 00:00:00 2001 From: kosaki Date: Tue, 8 Oct 2013 02:14:21 +0000 Subject: [PATCH] * cont.c: disable FIBER_USE_NATIVE on GNU/Hurd because it doesn't support a combination getcontext() and threads. Patch by Gabriele Giacone (1o5g4r8o@gmail.com). [Bug #8990][ruby-core:57685] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43193 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 6 ++++++ cont.c | 7 +++++++ 2 files changed, 13 insertions(+) diff --git a/ChangeLog b/ChangeLog index 3f79d3b777..7fb5ac6e0b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Tue Oct 8 10:56:39 2013 KOSAKI Motohiro + + * cont.c: disable FIBER_USE_NATIVE on GNU/Hurd because it doesn't + support a combination getcontext() and threads. Patch by + Gabriele Giacone (1o5g4r8o@gmail.com). [Bug #8990][ruby-core:57685] + Tue Oct 8 05:58:12 2013 Tanaka Akira * lib/time.rb (Time.strptime): Time.strptime('0', '%s') returns local diff --git a/cont.c b/cont.c index fe00cb35c7..5c1f10e571 100644 --- a/cont.c +++ b/cont.c @@ -44,6 +44,13 @@ /* At least, Linux/ia64's getcontext(3) doesn't save register window. */ # define FIBER_USE_NATIVE 0 +# elif defined(__GNU__) +/* GNU/Hurd doesn't fully support getcontext, setcontext, makecontext + * and swapcontext functions. Disabling their usage till support is + * implemented. More info at + * http://darnassus.sceen.net/~hurd-web/open_issues/glibc/#getcontext + */ +# define FIBER_USE_NATIVE 0 # else # define FIBER_USE_NATIVE 1 # endif