[DRE-maint] Bug#1012247: ruby3.1: Please build with --with-coroutine=ucontext on x32

John Paul Adrian Glaubitz glaubitz at physik.fu-berlin.de
Thu Jun 2 17:10:26 BST 2022


Hi Antonio!

On 6/2/22 15:58, John Paul Adrian Glaubitz wrote:
> On 6/2/22 15:43, Antonio Terceiro wrote:
>> isn't this something that should be done in configure.ac instead (and
>> submitted upstream)? there's a big switch statement there to select the
>> type of coroutine.
> 
> Sure, I can send a patch later. I just didn't have the time to dig through
> the code to address the issue. Probably the match for "x86_64-*-*" needs
> to be refined in configure.ac.

x32 is actually covered by configure.ac, but there is a bug as the variable
is named rb_cv_coroutine instead of coroutine_type which is why the configure
script fails.

The following patch fixes the problem:

--- ruby3.1-3.1.2.orig/configure.ac
+++ ruby3.1-3.1.2/configure.ac
@@ -2525,7 +2525,7 @@ AS_CASE([$coroutine_type], [yes|''], [
             coroutine_type=arm64
         ],
         [x86_64-linux-gnux32], [
-            rb_cv_coroutine=ucontext
+            coroutine_type=ucontext
         ],
         [x*64-linux*], [
             AS_CASE(["$ac_cv_sizeof_voidp"],

However, since upstream removed the x32 part [1], I don't know whether they would accept
such a change.

Adrian

> [1] https://github.com/ruby/ruby/blob/master/configure.ac#L2539

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer
`. `'   Physicist
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913



More information about the Pkg-ruby-extras-maintainers mailing list