Jon Forums wrote in post #1062852:
> Eric Hodel wrote in post #1062725:
>> On May 28, 2012, at 03:57, Iaki Baz Castillo wrote:
>>
>>> Hi, depending whether my Ruby C extension is being compiled on *nix or
>>> Windows, I need some #defines (i.e: OS_UNIX or OS_WIN).
>>>
>>> I see no way in MKMF documentation to generate a #define (based on
>>> RbConfig["host_os"] for example).
>>
>> [...SNIP...]
>>
>> The host_* values come from host that compiled ruby.  When ruby is
>> cross-compiled these values won't match the target and your gem will
>> fail to compile.
>>
>> You should use target_* values as these values match the target ruby was
>> compiled for.
>>
>> See: http://sources.redhat.com/autobook/autobook/autobook_261.html
>
> [...SNIP...]
>
> I believe it's more correct to use `RbConfig::CONFIG['host_os']` to
> determine *nix v. Windows.

Forgot to include the following doco link to compare with the link Eric
provided.

http://www.gnu.org/savannah-checkouts/gnu/autoconf/manual/autoconf-2.69/html_node/System-Type.html#System-Type

-- 
Posted via http://www.ruby-forum.com/.