RubyCocoa : GettingStarted

Requirements


If you decided to built Ruby by yourself and not using the version Apple provides, make sure you compiled it as a shared library, passing the --enabled-shared option to the configure script. By default this option is not activated.

Binary Releases

The easiest way to get started with RubyCocoa is probably to install the latest binary release. You can grab the binaries from the files repository. They have a .dmg file extension.

Once the release disk is mounted on your system, you will find an installer. Just double-click on it, then follow the steps.

Sources Releases

If you don't want or cannot use the binary releases described earlier, it is still possible to grab a sources tarball for every release. You can grab them from the files repository. They have a .tgz extension.

NOTE: You can't install RubyCocoa from source if you have installed Safari 3 Beta. It will fail at the config phase. You can reinstall Safari 3 Beta after installing RubyCocoa, however you will miss Webkit support in RubyCocoa. The best thing would be to revert to the original version of WebKit before building RubyCocoa.

Once you have uncompressed the tarball, you can build the project by issuing the following commands in the terminal:

$ ruby install.rb config
$ ruby install.rb setup
$ sudo ruby install.rb install


If you want to customize the build, you can pass some options to the config phase. Type the following to get more help on this:

$ ruby install.rb --help


Alternatively, you can also generate the RDoc files (refer to BridgeDoc for more information):

$ ruby install.rb doc


Troubleshooting

You should use the patch for rexml/document.rb from this message if during the config phase you get the following error:

BSROOT="/Users/stephen/dev/ruby/src/rubycocoa/framework/bridge-support"
CFLAGS="" /usr/local/bin/ruby build.rb
Generating BridgeSupport metadata for: CoreFoundation ...
    Collect metadata (20.65495 seconds)
/usr/local/lib/ruby/1.8/rexml/document.rb:186:in `write': undefined
local variable or method `transitive'
for <UNDEFINED> ...
</>:REXML::Document (NameError)
        from ./gen_bridge_metadata.rb:1516:in `generate_xml'
        from ./gen_bridge_metadata.rb:1516:in `open'

        from ./gen_bridge_metadata.rb:1516:in `generate_xml'
        from ./gen_bridge_metadata.rb:542:in `write'

        from build.rb:106
        from build.rb:50:in `measure'
        from build.rb:104
        from build.rb:62:in `each'

        from build.rb:62
config failed
hook /Users/stephen/dev/ruby/src/rubycocoa/framework/post-config.rb failed:
'system
BSROOT="/Users/stephen/dev/ruby/src/rubycocoa/framework/bridge-support"
CFLAGS="" /usr/local/bin/ruby build.rb'
failed


The Bleeding-Edge

You can always grab the latest bits from the SVN trunk:

$ svn co https://rubycocoa.svn.sourceforge.net/svnroot/rubycocoa/trunk/src rubycocoa


Then you can simply follow the same instructions for the source release to build and install the project.

You can browse the subversion repository too.

And then?!

Now that RubyCocoa is installed on your machine, you can go further by reading the documentation, trying the samples or watching some screencasts.

If it didn't work as promised, feel free to contact us.
© 2001-2007 The RubyCocoa Project. Powered by Wikka Wakka Wiki 1.1.6.3
SourceForge.net Logo
Page was generated in 0.2974 seconds