Installing IO (Language) on Mac OS X (Snow Leopard)


Io is an interesting prototype-based programming language, so I wanted to give it a try.

Unfortunately, the installation process is not the simplest thing in the world, but after a couple of days struggling with it, I had success and I want to share with you my recipe.

Brew – Your best friend

Forget Macports or Fink. They are junk. Install Brew instead!
Brew is much more conservative and less invasive, compared to the former ones. Once installed, you can easily install and remove packages with “brew search <something>” and “sudo brew install <something>” or “sudo brew remove <something>”.

Part I – Cloning is the way

The first thing I suggest to you is to clone the Io repo, with something like this:

git clone https://github.com/stevedekorte/io.git

Then you need to open the CMakeLists.txt, scroll until line 143 and change this:

string(REGEX REPLACE "(.......)." "\\1" IO_GIT_REV ${IO_GIT_REV})

Into this:

string(REGEX REPLACE "(.......)." "\\1" IO_GIT_REV ${IO_GIT_REV} "" "")

Now the fun begins.

Cmake – Use the Graphic Frontend, Luke!

CMake makes the installation and compiling phases easier. I suggest you to download the graphic frontend (I don’t remember which version I’ve downloaded, but I have the CMake application into Applications folder). If you are new to CMake these are the brain-dead simple instructions to follow:

  1. Open CMake.app
  2. When CMake asks you “Where is the source code”, put the cloned repo directory (e.g /Users/alfredodinapoli/github/io)
  3. When CMake asks you “Where to build the binaries”, put the cloned repo dir (e.g /Users/alfredodinapoli/github/io)
  4. Click on Configure – Use the default option (Makefiles)
  5. Click on Generate

Now go into the cloned repo dir and type:

sudo make install

If the compiling phase complains about some libraries missing, consider to install through Brew these packages:

  1. ossp-uuid
  2. pcre

Obviously every time you install a new package, is a good option to refresh the Makefile through the usual cycle Configure/Generate.

Now everything must be allright and the installation MUST succed! If not, well, we have a problem :)

Happy hacking with Io Language!

Alfredo



About these ads

2 pensieri su “Installing IO (Language) on Mac OS X (Snow Leopard)

Rispondi

Inserisci i tuoi dati qui sotto o clicca su un'icona per effettuare l'accesso:

Logo WordPress.com

Stai commentando usando il tuo account WordPress.com. Chiudi sessione / Modifica )

Foto Twitter

Stai commentando usando il tuo account Twitter. Chiudi sessione / Modifica )

Foto di Facebook

Stai commentando usando il tuo account Facebook. Chiudi sessione / Modifica )

Google+ photo

Stai commentando usando il tuo account Google+. Chiudi sessione / Modifica )

Connessione a %s...