From: Maurice Smulders Date: 2020-06-10T11:16:37-06:00 Subject: [ruby-core:98716] Ruby 2.7.x coroutine support on 32 bit PowerPC e500v2 I am trying to cross compile Ruby 2.7.1 using buildroot on PPC/32, and am able to only do that using the --with-coroutine=copy suboptimal configure option. I understand that this option is far from optimal - especially because the actual HW platform is a single core MPC8548e PPC/32 e500v2/spe processor. Where do the coroutine sources come from? Is there a ppc/32 variant in that original repo? When I do NOT use copy (the library configured is uclibc 1.0.32) the following error messages are shown: compiling coroutine/ucontext/Context.c compiling mjit.c In file included from coroutine/ucontext/Context.c:14:0: coroutine/ucontext/Context.h:22:5: error: unknown type name 'ucontext_t' ucontext_t state; ^~~~~~~~~~ In file included from coroutine/ucontext/Context.c:14:0: coroutine/ucontext/Context.h: In function 'coroutine_initialize_main': coroutine/ucontext/Context.h:32:5: warning: implicit declaration of function 'getcontext' [-Wimplicit-function-declaration] getcontext(&context->state); ^~~~~~~~~~ In file included from coroutine/ucontext/Context.c:14:0: coroutine/ucontext/Context.h: In function 'coroutine_initialize': coroutine/ucontext/Context.h:45:19: error: request for member 'uc_stack' in something not a structure or union context->state.uc_stack.ss_size = size; ^ coroutine/ucontext/Context.h:47:19: error: request for member 'uc_stack' in something not a structure or union context->state.uc_stack.ss_sp = (char*)stack; ^ coroutine/ucontext/Context.h:48:19: error: request for member 'uc_stack' in something not a structure or union context->state.uc_stack.ss_flags = 0; ^ coroutine/ucontext/Context.h:49:19: error: request for member 'uc_link' in something not a structure or union context->state.uc_link = NULL; ^ In file included from coroutine/ucontext/Context.c:14:0: coroutine/ucontext/Context.h:51:5: warning: implicit declaration of function 'makecontext' [-Wimplicit-function-declaration] makecontext(&context->state, (void(*)(void))coroutine_trampoline, 2, (void*)start, (void*)context); ^~~~~~~~~~~ In file included from coroutine/ucontext/Context.c:14:0: coroutine/ucontext/Context.h: In function 'coroutine_transfer': coroutine/ucontext/Context.h:59:5: warning: implicit declaration of function 'swapcontext' [-Wimplicit-function-declaration] swapcontext(¤t->state, &target->state); ^~~~~~~~~~~ coroutine/ucontext/Context.h: In function 'coroutine_destroy': coroutine/ucontext/Context.h:67:19: error: request for member 'uc_stack' in something not a structure or union context->state.uc_stack.ss_sp = NULL; ^ In file included from coroutine/ucontext/Context.c:14:0: coroutine/ucontext/Context.h:68:19: error: request for member 'uc_stack' in something not a structure or union context->state.uc_stack.ss_size = 0; ^ Makefile:420: recipe for target 'coroutine/ucontext/Context.o' failed make[2]: *** [coroutine/ucontext/Context.o] Error 1 make[2]: *** Waiting for unfinished jobs.... package/pkg-generic.mk:266: recipe for target '/root/build/buildroot-top/buildroot/output/build/ruby-2.7.1/.stamp_built' failed make[1]: *** [/root/build/buildroot-top/buildroot/output/build/ruby-2.7.1/.stamp_built] Error 2 buildroot/Makefile:84: recipe for target '_all' failed make: *** [_all] Error 2 - Maurice Unsubscribe: