From: nobu@... Date: 2017-04-04T13:39:32+00:00 Subject: [ruby-core:80561] [Ruby trunk Bug#13400] mcontext struct has differently-named members in OS X 10.4 Issue #13400 has been updated by nobu (Nobuyoshi Nakada). OS X 10.4 has been outdated long ago. I'm not positive to keep supporting such old OSs. ---------------------------------------- Bug #13400: mcontext struct has differently-named members in OS X 10.4 https://bugs.ruby-lang.org/issues/13400#change-64061 * Author: mistydemeo (Misty De Meo) * Status: Open * Priority: Normal * Assignee: * Target version: * ruby -v: ruby 2.2.3p173 (2015-08-18 revision 51636) [i386-darwin8.0] * Backport: 2.2: UNKNOWN, 2.3: UNKNOWN, 2.4: UNKNOWN ---------------------------------------- The `mcontext` struct, used by Ruby in `signal.c` and `vm_dump.c`, has a different structure in OS X 10.4 than it does in later versions. In OS X 10.5 and later, its members' names all start with a double underscore (`__`); in 10.4, they don't. Similarly, the `__ss`/`ss` struct's members all begin with `__`, for example `__esp`, while in 10.4 they don't, for example `esp`. In addition, `vm_dump.c` is missing an `#include ` in order to access the `mcontext` struct definition. Usage in `signal.c` is here: https://github.com/ruby/ruby/blob/trunk/signal.c#L790-L794 Usage in `vm_dump.c` is here: https://github.com/ruby/ruby/blob/trunk/vm_dump.c#L460-L480 https://github.com/ruby/ruby/blob/trunk/vm_dump.c#L825 I tested using Ruby 2.2.3p173 and Ruby 2.4; the sections of these files in trunk are unchanged and still have the bug in question. I'm building for i386. -- https://bugs.ruby-lang.org/ Unsubscribe: