Permalink
Browse files

Add FFI::Platform::IS_MAC constant

MRI FFI contains a number of constants missing from RBX. This
commit adds IS_MAC to the case statement defining Platform const.

TODO: add IS_GNU, IS_LINUX, IS_FREEBSD, IS_OPENBSD, IS_BSD
  • Loading branch information...
1 parent 6f3a7ab commit 04c3b6e518147f2961e055a492e8a230a49ec11e RageLtMan committed Dec 11, 2012
Showing with 3 additions and 0 deletions.
  1. +3 −0 kernel/platform/ffi.rb
View
@@ -229,14 +229,17 @@ module FFI::Platform
when Rubinius.windows?
LIBSUFFIX = "dll"
IS_WINDOWS = true
+ IS_MAC = false
OS = 'windows'
when Rubinius.darwin?
LIBSUFFIX = "dylib"
IS_WINDOWS = false
+ IS_MAC = true
OS = 'darwin'
else
LIBSUFFIX = "so"
IS_WINDOWS = false
+ IS_MAC = false
OS = 'linux'
end

0 comments on commit 04c3b6e

Please sign in to comment.