Instructions for building OVITO on MacOS X.

- Download Boost library source code from www.boost.org, extract archive. For the following, we assume that Boost has been extracted to the directory ~/boost_1_43_0/

- Download zlib library source code from www.zlib.net, extract archive. For the following, we assume that the zlib code has been extracted to the directory ~/zlib-1.2.5/

- In newer versions of zlib, the file gzio.c is missing, which is required by Boost. Create it:

    touch ~/zlib-1.2.5/gzio.c

- Compile the Boost library (only those parts needed by Ovito):
   
    cd ~/boost_1_43_0/
    ./bootstrap.sh --with-libraries=iostreams,serialization
    env ZLIB_SOURCE=~/zlib-1.2.5 ./bjam stage

- Download and install the Qt framework for Mac (the complete SDK is not required).

- Download and install a Subversion client. 

- Download and install the CMake package.

- Create a directory for Ovito:

    mkdir ~/ovito/
    mkdir ~/ovito/source

- Download Ovito's source code:

    cd ~/ovito/source
    svn co https://ovito.svn.sourceforge.net/svnroot/ovito/trunk/ .

- Configure build:

    mkdir ~/ovito/release
    cd ~/ovito/release
    ccmake -D BOOST_ROOT=${HOME}/boost_1_43_0/ ~/ovito/source

- In the ccmake configuration program, press 'c' to configure. Make the following settings:
   
    CMAKE_BUILD_TYPE: Release
    CMAKE_INSTALL_PREFIX: ~/ovito/release_install
    
- Press 'c' again, and then 'g' to generate a makefile. Run:

    make install

- Your are done. The Ovito program can be found in ~/ovito/release_install/

