wiki:InstallGuides/ChasteInstallationOnOSXYosemite

Installing Chaste on OSX yosemite

Warning: we're currently writing this guide and currently it only allows the use of 'cell based' code

This install guide is based upon a fresh install of OSX Yosemite in October 2014.

It has been tested on El Capitan in June 2016

Xcode

Install Xcode from app store. (Version 7.3)

  • Xcode comes with Subversion version 1.7.1. Alternatively, Homebrew has version 1.8 of Subversion.
  • Xcode provides the "g++" compiler

Home Brew

see http://mxcl.github.com/homebrew/

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

Later libraries (PETSc, METIS, VTK and parMETIS) need a "science" repository

brew tap homebrew/science

If you're using the cell based code only you can roll the next few installs together. However, some of these (PETSc and Sundials) need some configuration to build in the correct way to work for all of the code base (see Mountain Lion instructons). It will take a while.

brew install wget scons xerces-c petsc parmetis metis vtk 
brew install sundials --with-mpi
brew install hdf5 --with-mpi

vtk5 is no longer supported but can be installed with

brew install rdeits/director/vtk5

Codesynthesis XSD

Codesynthesis XSD is not available in homebrew and must be installed directly:

wget http://www.codesynthesis.com/download/xsd/3.3/macosx/i686/xsd-3.3.0-i686-macosx.tar.bz2
tar xvfz xsd-3.3.0-i686-macosx.tar.bz2
#These instructions assume that homebrew has created /usr/local/ and that the current user has permission to write to it.
cp xsd-3.3.0-i686-macosx/bin/xsd /usr/local/bin/
cp -r xsd-3.3.0-i686-macosx/libxsd /usr/local/opt/

You also need to change the call setg (b, b, e) on line 35 of xsd/cxx/zc-istream.txx like this:

bash-3.2$ diff -u /usr/local/opt/libxsd/xsd/cxx/zc-istream.txx.orig /usr/local/opt/libxsd/xsd/cxx/zc-istream.txx
--- /usr/local/lib/libxsd/xsd/cxx/zc-istream.txx.orig   2013-07-10 11:00:23.000000000 +0100
+++ /usr/local/lib/libxsd/xsd/cxx/zc-istream.txx        2013-07-10 11:00:59.000000000 +0100
@@ -32,7 +32,7 @@
       C* b (const_cast<C*> (str_.data ()));
       C* e (b + str_.size ());
 
-      setg (b, b, e);
+      std::streambuf::setg (b, b, e);
     }

Get the source code

See

https://chaste.cs.ox.ac.uk/trac/wiki/ChasteGuides/AccessCodeRepository

Host Config

Use attachment:local.py (experimental) for your host config?. Save it as python/hostconfig/local.py.

GOT TO HERE and cell_based works.

TODO: openmpi valgrind

Python XML tool support

Libraries needed by PyCml, the heart component and the Functional Curation bolt-on project.

# Note that Amara at version 2 is not suitable, so version 1.2 is forced.
sudo easy_install https://pypi.python.org/packages/2.5/A/Amara/Amara-1.2.0.2-py2.5.egg
sudo easy_install rdflib
sudo easy_install lxml

More for the developer

Eclipse

  • Download the Eclipse IDE for C++ developers (or a more appropriate file) from http://www.eclipse.org/downloads/
  • Open the resulting tar file to produce a folder named "eclipse"
  • Drag and drop the "eclipse" folder to "Applications" in FileFinder
  • Open from Applications -> eclipse -> Eclipse
    • (You might be prompted to install a Java runtime when you first run Eclipse)
  • If you want to alias or add the path, the location is /Applications/eclipse/eclipse

Valgrind

Valgrind version 3.8.1 (not necessary, but useful to the serious developer)

brew install valgrind

Handy things

To be able to see the tmp folder in finder use

sudo chflags nohidden /tmp

Useful aliases to add to ~/.bash_profile

nano ~/.bash_profile
alias eclipse=/Applications/eclipse/eclipse
alias cdchaste='cd /Users/chaste/eclipse/workspace/Chaste' #Or similar
Last modified 4 years ago Last modified on Jun 15, 2016, 5:21:19 AM

Attachments (1)

Download all attachments as: .zip