From f540c43daed6594f055f27cd4c9f17b90a454743 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 17 Jan 2017 16:22:14 +0100 Subject: [PATCH] Apply patch fixing rubygem-mongo build failures. --- ...nhelper.c-block-argument-at-tailcall.patch | 36 +++++++++++++++++++ ruby.spec | 9 ++++- 2 files changed, 44 insertions(+), 1 deletion(-) create mode 100644 ruby-2.4.0-vm_insnhelper.c-block-argument-at-tailcall.patch diff --git a/ruby-2.4.0-vm_insnhelper.c-block-argument-at-tailcall.patch b/ruby-2.4.0-vm_insnhelper.c-block-argument-at-tailcall.patch new file mode 100644 index 0000000..cb8fe26 --- /dev/null +++ b/ruby-2.4.0-vm_insnhelper.c-block-argument-at-tailcall.patch @@ -0,0 +1,36 @@ +From ff3496b0116ed2ed589d000b7bfca3d8288b009c Mon Sep 17 00:00:00 2001 +From: nobu +Date: Mon, 9 Jan 2017 02:55:39 +0000 +Subject: [PATCH] vm_insnhelper.c: block argument at tailcall + +* vm_insnhelper.c (vm_call_iseq_setup_tailcall): check interrupts + after set up the new frame, not the passed block to be clobbered + by invoked finalizers and so on. [ruby-core:78981] [Bug #13107] + +git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57293 b2dd03c8-39d4-4d8f-98ff-823fe69b080e +--- + vm_insnhelper.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/vm_insnhelper.c b/vm_insnhelper.c +index b580412..662a2d6 100644 +--- a/vm_insnhelper.c ++++ b/vm_insnhelper.c +@@ -1538,8 +1538,6 @@ vm_call_iseq_setup_tailcall(rb_thread_t *th, rb_control_frame_t *cfp, struct rb_ + vm_pop_frame(th, cfp, cfp->ep); + cfp = th->cfp; + +- RUBY_VM_CHECK_INTS(th); +- + sp_orig = sp = cfp->sp; + + /* push self */ +@@ -1558,6 +1556,8 @@ vm_call_iseq_setup_tailcall(rb_thread_t *th, rb_control_frame_t *cfp, struct rb_ + iseq->body->stack_max); + + cfp->sp = sp_orig; ++ RUBY_VM_CHECK_INTS(th); ++ + return Qundef; + } + diff --git a/ruby.spec b/ruby.spec index f89276e..cdb2047 100644 --- a/ruby.spec +++ b/ruby.spec @@ -21,7 +21,7 @@ %endif -%global release 74 +%global release 75 %{!?release_string:%global release_string %{?development_release:0.}%{release}%{?development_release:.%{development_release}}%{?dist}} # The RubyGems library has to stay out of Ruby directory three, since the @@ -128,6 +128,9 @@ Patch7: ruby-2.2.3-Generate-preludes-using-miniruby.patch # hardening features of glibc (rhbz#1361037). # https://bugs.ruby-lang.org/issues/12666 Patch9: ruby-2.3.1-Rely-on-ldd-to-detect-glibc.patch +# This fixed rubygem-mongo build failures and may be something else as well. +# https://bugs.ruby-lang.org/issues/13107 +Patch10: ruby-2.4.0-vm_insnhelper.c-block-argument-at-tailcall.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} Suggests: rubypick @@ -506,6 +509,7 @@ rm -rf ext/fiddle/libffi* %patch6 -p1 %patch7 -p1 %patch9 -p1 +%patch10 -p1 # Provide an example of usage of the tapset: cp -a %{SOURCE3} . @@ -1016,6 +1020,9 @@ make check TESTS="-v $DISABLE_TESTS" %{gem_dir}/specifications/xmlrpc-%{xmlrpc_version}.gemspec %changelog +* Tue Jan 17 2017 Vít Ondruch - 2.4.0-75 +- Apply patch fixing rubygem-mongo build failures. + * Fri Jan 13 2017 Mamoru TASAKA - 2.4.0-74 - Rebuild again for f26-ruby24 sidetag