ruby-changes:50295
From: mame <ko1@a...>
Date: Thu, 15 Feb 2018 10:59:22 +0900 (JST)
Subject: [ruby-changes:50295] mame:r62410 (trunk): gc.c: force STACK_GROW_DIRECTION for emscripten
mame 2018-02-15 10:59:17 +0900 (Thu, 15 Feb 2018) New Revision: 62410 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=62410 Log: gc.c: force STACK_GROW_DIRECTION for emscripten The configure script fails to guess the direction on emscripten. Perhaps this is because of https://github.com/kripken/emscripten/issues/2093 Modified files: trunk/gc.c Index: gc.c =================================================================== --- gc.c (revision 62409) +++ gc.c (revision 62410) @@ -3996,6 +3996,11 @@ init_mark_stack(mark_stack_t *stack) https://github.com/ruby/ruby/blob/trunk/gc.c#L3996 #define STACK_END (ec->machine.stack_end) #define STACK_LEVEL_MAX (ec->machine.stack_maxsize/sizeof(VALUE)) +#ifdef __EMSCRIPTEN__ +#undef STACK_GROW_DIRECTION +#define STACK_GROW_DIRECTION 1 +#endif + #if STACK_GROW_DIRECTION < 0 # define STACK_LENGTH (size_t)(STACK_START - STACK_END) #elif STACK_GROW_DIRECTION > 0 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/