Home  · Classes  · Annotated Classes  · Modules  · Members  · Namespaces  · Related Pages
Building OpenMS on Mac OS X

Introduction

This document addresses OpenMS users and explains the installation procedure for building OpenMS from its sources. If you only want to use the OpenMS Proteomics Pipeline (TOPP), you are strongly encouraged to download the binary installer (see here), instead of building OpenMS from sources. Be aware though that we do not provide binary installers for every MacOS version. For more information read the install instructions for the TOPP binaries.

This document especially considers the installation of several libraries which are required by OpenMS. Most of these libraries are made available in our "contrib-package" (see below).
If you encounter errors during configuring/compiling our software, have a look at our "Known Issues" section (documentation), maybe the error is already known. If not, please write to the mailing list or report the error on our issue tracker.

Package Mangers

We suggest to use either Homebrew or MacPorts as they contain most of the following requirements for OpenMS and ease the process of upgrading those dependencies.

Required applications

In order to compile OpenMS, several applications need to be installed:

If your OpenMS version is a development version from SVN, the following applications are needed in order to create the OpenMS documentation:


Installing the contrib package

In order to facilitate the installation of the libraries required for OpenMS, we composed a "contrib-package" containing the libraries Boost, GSL, libSVM, SeqAn, glpk, zlib, bzip2 and Xerces-C.

The contrib package is contained in the OpenMS release package and is available inside the contrib directory in the OpenMS directory.

If you are using the developer version of OpenMS, you have to check out the contrib from Sourceforge SVN repository

svn co "https://open-ms.svn.sourceforge.net/svnroot/open-ms/contrib"

CMake is used to check your system and build the contrib libraries.

Note
As of OpenMS 1.10 compiling OpenMS with the Apple GCC 4.2 compiler can lead to errors due to the update of BOOST to version 1.52. Please use the shipped clang compiler instead (clang/clang++) to avoid this problem.
  1. Open a Terminal (/Applications/Utilities/Terminal.app)
  2. Create a build directory for the OpenMS contrib e.g.,

    $ mkdir ~/openms-development/contrib_build
  3. Enter the created directory and call cmake to build the contrib

    $ cd <path_to_contrib_build>
    $ cmake -D CMAKE_CXX_COMPILER=clang++ -D CMAKE_C_COMPILER=clang <path_to_contrib>

    Example:

    cd ~/openms-development/contrib_build
    cmake -D CMAKE_CXX_COMPILER=clang++ -D CMAKE_C_COMPILER=clang ~/openms-development/contrib

If everything worked, the following sub-directories were created under in the contrib build directory:

Note
To avoid problems while building the libraries contained in the contrib package, the path to your contrib directory should not contain any spaces.

Installing OpenMS

Assuming you have successfully installed the dependent libraries, you need to get the OpenMS source code. The latest stable version of OpenMS can be found in the download page. For further (e.g. latest developer version from SVN) info see the download instructions.

  1. Open a Terminal (/Applications/Utilities/Terminal.app)
  2. Create a build directory for OpenMS, e.g.,

    $ mkdir ~/openms-development/openms_build
  3. Call cmake to create the build system there

    cd <path_to_OpenMS_build>
    cmake -D CMAKE_FIND_ROOT_PATH=<path_to_contrib_build> <path_to_OpenMS>

    You can set CMake variables using the -D VARIABLE=VALUE option. A full list of the CMake variables is shown when you execute

    ccmake ~/openms-development/openms_build
    Note
    You need to execute cmake at least once before ccmake can be used.

The most important CMake variables are:

CMAKE_FIND_ROOT_PATH Additional search path for the contrib libraries. If not set the the location is assumed to be <path_to_OpenMS>/contrib.
QT_QMAKE_EXECUTABLE Defines the Qt 'qmake' application to identify the corresponding Qt installation. This variable only needs to be set if qmake is not in the PATH.
CMAKE_BUILD_TYPE Should be either 'Release' (optimization enabled) or 'Debug' (debug info and precondition/postcondiction checks enabled).
The default is Release.
QT_DB_PLUGIN Defines the Qt database type. By default MySQL is used.
CMAKE_CXX_COMPILER Defines the C++ compiler to use.
CMAKE_C_COMPILER Defines the C compiler to use. This should match the C++ compiler. Mixing compilers (e.g., clang++ for C++ and gcc for C) can lead to undefined behavior as some internal settings (e.g., OpenMP support) are determined using the C compiler and are assumed to be the same for the C++ compiler.
SEARCH_ENGINES_DIRECTORY (optional) The location where the ID search engines are located. This directory should have the same structure as the one in the OpenMS svn repository. This directory is needed to build the installer for OpenMS.
PYOPENMS Use ON to also build the Python bindings, see also pyOpenMS (Python bindings).

After CMake was executed, you can list the make targets by calling:

make targets

In order to build the OpenMS library and TOPP tools execute the following command:

make

The TOPP tools should now be ready to use. The executables are located in the bin/ folder of the build directory. Add this folder to your PATH variable for easy access.


Testing your OpenMS / TOPP installation

After you have installed OpenMS and TOPP, you should test your installation by executing the following command:

make test_build
make test
Note
To enable DB connectivity tests, use the following CMake parameters:
  • DB_TEST
  • DB_TEST_HOST
  • DB_TEST_PORT
  • DB_TEST_DB
  • DB_TEST_USER
  • DB_TEST_PW

OpenMS / TOPP release 1.11.1 Documentation generated on Thu Nov 14 2013 11:19:25 using doxygen 1.8.5