Starting with Snow Leopard (OS X v10.6) Apple bundles 64-bit ruby by default. Unfortunately, there is no 64-bit Tk bundled, so the following ruby code will fail:
require 'tk'
Is it some easy way to enable Tk for Ruby in Snow Leopard and higher? Like installing 32-bit ruby or whatever. I have tried to recompile Ruby with Tk support but it seems not that easy - tutorials found in google refers to some options in Ruby's ./configure script that don't exists in actual Rby code downloaded from official site :(. I will be glad for any hints - i have a Ruby app with Tk GUI and need to enable my users to use it :)
Tk builds fine in 64-bit mode on OSX, but only if you've got sources from the 8.6 series«ZIP»«TGZ» (still in beta for various reasons, but quite usable). You'll want to ensure you configure with --enable-aqua --enable-64bit of course, but I assume that's pretty much obvious.
(Alas, I can't say how to then integrate the build of Tk with your Ruby installation, though there is some documentation online that seems to be somewhat relevant. I emphasize that I've only googled for it though; on this I don't speak from experience.)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With