Home | Download/Install | Documentation | Packages | Screenshots | News | Forum/Mailing-lists | Contact | GForge

Installation on a Mac OS X

Installation notes

OpenAlea installation is done in two steps.

  1. install all dependencies required by OpenAlea as described in this page
  2. once dependencies installed, install OpenAlea as described in Building and Installing OpenAlea

To install dependencies on Mac OS X, openalea can rely on two package managers, namely Homebrew and Macports.

MacPorts

MacPorts is a standard Mac OS X tool to facilitate the process of installation of 3rd party programs and libraries. Please follow the instructions on MacPorts webpage to correctly install and setup MacPort installation.

Using MacPorts facilitates the process of installation of Openalea dependencies. Please be patient during the process, since some packages have to be compiled by MacPorts.

  • To install OpenAlea dependencies with Macports, please have a look to section corresponding to your Mac OS X version (see for instance 10.9)
MacPorts is recommend system. Documentation for homebrew is not officialy maintained and so can be outdated

Homebrew

Homebrew is a package management system that simplifies the installation of software on the Mac OS X operating system. It is a free/open source software project to simplify installation of other free/open source software. It is similar in aim and function to MacPorts and Fink (ref: wikipedia)

For the installation, follow these 3 steps:

Which one ?

Using MacPorts or Homebrew for Openalea installation is not required, but strongly recommended. Both can be used, so choose the one you prefer but use only one !

Installation using MacPort

Installation on Mac OS X 10.10 Yosemite

Because Mac OS X 10.10 is very young, these instructions will certainly change.

See installation for Mac OS X 10.9. Main changes is the renaming of the py27-pil module in py27-Pillow by MacPort.

sudo port install py27-Pillow 

Installation on Mac OS X 10.9 Mavericks

Openalea works well on OS X 10.9 but several VPlant packages are not yet available. We are working on it to provide full support as soon as possible.

Click to display ⇲

Click to hide ⇱

Click to hide ⇱

Install X11 and Xcode. See the MacPort documentation.
# Update MacPort
sudo port -v selfupdate
 
# Install Python 2.7
sudo port install python27
 
# Make python2.7 the default
sudo port select --set python python27
 
# Install the Scientific Python stack
sudo port install py27-numpy py27-scipy
 
# Install Qt and PyQt
sudo port install qt4-mac 
sudo port install py27-pyqt4 +scintilla
sudo port install py27-qscintilla
 
sudo port install py27-matplotlib -tkinter +qt4 +webagg
 
# Install other Python utilities
sudo port install py27-pil py27-opengl py27-nose py27-sphinx
sudo port select --set sphinx py27-sphinx
 
sudo port install py27-ipython +notebook +parallel +pyqt4
 
# Make ipython2.7 the default
sudo port select --set ipython ipython27
 
# Install C++ libraries
sudo port install scons qhull
sudo port install gnuplot -aquaterm -luaterm -pangocairo -wxwidgets +qt
sudo port install boost bison flex
 
sudo port install cgal libANN
sudo port install py27-PyQGLViewer
  • If macport can't install py27-PyQGLViewer, install pyqglviewer from sources.

First download http://gforge.inria.fr/frs/download.php/file/34636/PyQGLViewer-0.13.tgz

Then unzip the file.

In the repertory PyQGLViewer:

python configure.py
make
[sudo] make install
  • If it is not done automatically, update the PATH
export PATH=/opt/local/Library/Frameworks/Python.framework/Versions/2.7/bin:$PATH
In OpenAlea and VPlants source directory, if exists, rename options_macports.py to options.py.
If you work on image processing, you should install these libraries
sudo port install tiff
 
# pylibtiff to read/write tiff images
svn checkout https://pylibtiff.googlecode.com/svn/trunk/ pylibtiff-read-only
cd pylibtiff-read-only
python setup.py install
cd -
 
# pyLSM to read lsm files
easy_install pylsm
 
# Scikit-learn
sudo port install py-scikit-learn
 
 
# Vtk only
sudo port install vtk5 +python27 +qt4_mac
  • An upgrade of macport can cause a segmentation fault at the execution of openalealab and lpy, probably because boost has been compiled with a different compiler. To ensure that the same compiler is used everywhere, compile boost from sources (macport with -s option) and recompile both vplants and openalea:
sudo port -s install boost

Installation on Mac OS X 10.7 Lion and 10.8 Mountain Lion

Click to display ⇲

Click to hide ⇱

Click to hide ⇱

Install X11 and Xcode. See the MacPort documentation.
# Update MacPort
sudo port -v selfupdate
 
# Install Python 2.7
sudo port install python27
 
# Make python2.7 the default
sudo port select --set python python27
 
# Install the Scientific Python stack
sudo port install py27-numpy py27-scipy
 
# Install Qt and PyQt
sudo port install qt4-mac 
sudo port install py27-pyqt4 +scintilla
sudo port install py27-qscintilla
 
sudo port install py27-matplotlib -tkinter +qt4 +webagg
 
# Install other Python utilities
sudo port install py27-pil py27-opengl py27-nose py27-sphinx
sudo port select --set sphinx py27-sphinx
 
sudo port install py27-ipython +notebook +parallel +pyqt4
 
# Install C++ libraries
sudo port install scons qhull
sudo port install gnuplot -aquaterm -luaterm -pangocairo -wxwidgets +qt
sudo port install boost bison flex
 
sudo port install cgal libANN
sudo port install libPyQGLViewer py27-PyQGLViewer
  • Install OpenAlea from sources
  • Update the PATH
export PATH=/opt/local/Library/Frameworks/Python.framework/Versions/2.7/bin:$PATH

Installation using Homebrew

Click to display ⇲

Click to hide ⇱

Click to hide ⇱

Update your paths to be able to run programs installed from Homebrew directly.

Copy/paste this line at the end of your ~/.profile or ~/.bash_profile if it exists.

export PATH=/usr/local/bin:$PATH

Install Python :

# set up some taps and update brew
brew tap homebrew/science # a lot of cool formulae for scientific tools
brew tap homebrew/python # numpy, scipy
brew update && brew upgrade
 
# install a brewed python
brew install python
pip install --upgrade setuptools
pip install --upgrade pip
brew linkapps

Install dependencies

# Install Qt and PyQt
brew install qt --with-d-bus --with-qt3support
brew install sip pyqt
 
# install PIL, imagemagick, graphviz and other
# image generating stuff (qt is nice for viewing)
brew install imagemagick graphviz
brew install freetype
ln -s /usr/local/include/freetype2 /usr/local/include/freetype
brew install pillow
brew install matplotlib
 
# Useful python libraries
pip install nose sphinx pyparsing dateutils
pip install python-dateutil
 
 
#install scipy and numpy :
brew install scipy
 
# Ann
brew install https://raw.github.com/gag/homebrew-science/master/ann.rb
 
# ipython and notebook support
brew install zmq
pip install ipython[all]
 
# OpenAlea Dependencies
brew install gnuplot
pip install pyopengl
pip install scikit-learn
 
# Install Boost.Python
brew install boost
brew install boost-python
brew install homebrew/science/qhull
brew install cgal eigen
 
# Install PyQGLViewer
brew install qscintilla2 
brew install https://raw.github.com/gbaty/homebrew-formula/master/pyqglviewer.rb
sudo ln -s "/usr/local/Cellar/libqglviewer/2.5.1/QGLViewer.framework" "/Library/Frameworks/QGLViewer.framework"
ln -s /usr/local/Cellar/libqglviewer/2.5.1/QGLViewer.framework /usr/local/Frameworks/QGLViewer.framework
 
# Bison/Flex
brew install bison
brew install flex
 
brew install scons
If you work on image processing, you should install these libraries
brew install libtiff libpng giflib
 
# pylibtiff to read/write tiff images
svn checkout https://pylibtiff.googlecode.com/svn/trunk/ pylibtiff-read-only
cd pylibtiff-read-only
python setup.py install
cd -
 
# pyLSM to read lsm files
pip install http://launchpad.net/pylsm/trunk/0.1/+download/pylsm-0.1-r34.orig.tar.gz
 
# Scikit-learn
pip install scikit-learn
 
 
# Vtk only
brew install vtk --with-qt --with-python --with-pyqt
  • All dependencies are now installed.
  • You can now download OpenAlea, Vplant and ALinea sources.
  • Then if downloaded from archives, decompress it.
  • Finally go into source directory.
In OpenAlea and VPlants source directory, if exists, rename options_brew_maverick.py to options.py.

If you have an error with libJPEG (and/or libTIFF, libPng, libGIF, …) add to your ~/.profile:

IMGLIBS=/System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/
export DYLD_INSERT_LIBRARIES=$IMGLIBS/libJPEG.dylib:$IMGLIBS/libTIFF.dylib:$IMGLIBS/libPng.dylib:$IMGLIBS/libGIF.dylib

Installation on Mac OS X 10.7 Lion and 10.8 Mountain Lion

Click to display ⇲

Click to hide ⇱

Click to hide ⇱

Update your paths to be able to run programs installed from Homebrew directly.

Copy/paste this line at the end of your ~/.profile.

export PATH=/usr/local/bin:$PATH
export PYTHONPATH=$HOME/local/lib/python2.7/site-packages:/usr/local/lib/python2.7/site-packages/:$PYTHONPATH

Then install Python

# set up some taps and update brew
brew tap homebrew/science # a lot of cool formulae for scientific tools
brew tap homebrew/python # numpy, scipy
brew update && brew upgrade
 
# install a brewed python
brew install python
 
# Install Qt and PyQt
brew install qt --with-qt3support
brew install sip pyqt
 
# install PIL, imagemagick, graphviz and other
# image generating stuff (qt is nice for viewing)
brew install imagemagick graphviz
pip install pillow
 
pip install nose sphinx pyparsing dateutils
 
# install numpy and scipy
 
# install openblas (otherwise scipy's arpack tests will fail)
brew install openblas
brew install numpy --with-openblas
brew install scipy --with-openblas
 
# If openblas doesn't compile :
brew install numpy
brew install scipy
 
brew install ann
brew install matplotlib
 
# ipython and notebook support
brew install zmq
pip install ipython[all]
 
# OpenAlea Dependencies
brew install gnuplot
pip install pyopengl
 
# Install Boost.Python
brew install boost --build-from-source #option required for boost/python
brew install qhull 
brew install cgal eigen
 
# Install PyQGLViewer
brew install qscintilla2 
brew install https://raw.github.com/pradal/homebrew/master/Library/Formula/libqglviewer.rb
brew install https://raw.github.com/pradal/homebrew/master/Library/Formula/pyqglviewer.rb
 
brew install scons

If you have an error with libJPEG (and/or libTIFF, libPng, libGIF, …) add to your ~/.profile:

IMGLIBS=/System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/
export DYLD_INSERT_LIBRARIES=$IMGLIBS/libJPEG.dylib:$IMGLIBS/libTIFF.dylib:$IMGLIBS/libPng.dylib:$IMGLIBS/libGIF.dylib

Installation on Mac OS X 10.6 Snow Leopard

Installation on older Mac OS X Version

Uninstalling OpenAlea

Click to display ⇲

Click to hide ⇱

Click to hide ⇱

To uninstall OpenAlea, remove OpenAlea and all the config files
rm ~/.pydistutils.cfg # if this file exists
sudo vi /etc/bashrc # remove the line source ~/.openalea.sh if it exists
# modify the ~/.profile
# Remove all the eggs
# Remove all the shared libraries

Note for developpers

Click to display ⇲

Click to hide ⇱

Click to hide ⇱

If you happen to be a developer, please consider extending the Automated Dependency Builder to support Mac Os X.

Note for Python Scientists

Click to display ⇲

Click to hide ⇱

Click to hide ⇱

If you want further information about installing a scientific environemnt using Homebrew, please have a look to these links :
 
documentation/user/installation_mac.txt · Last modified: 2015/03/20 17:20 by user   Back to top
INRIA   INRA     CIRAD     AGROPOLIS
INRIA GForge RSS feed Valid XHTML 1.0 Valid CSS Driven by DokuWiki