This document describes, how to install binary programs of BioShell toolkit. See PyBioShell Installation page for instruction regarding Python bindings.

BioShell package has been written in C++11 and must be built before use. This is a quite easy process, which requires CMake ( and a relatively modern C++ compiler such as gcc 5.0 or clang 10.0

Just follow the steps below to compile the package:

The two additional sections below provide more information on customization of the building process:

1. Install zlib

BioShell requires zlib library so it can handle compressed files. You must install developer version of the library to be able to compile BioShell. On Ubuntu linux it can be installed by the command:

sudo apt-get install zlib1g-dev

2. Clone BioShell

If you haven’t done it yet, clone bioshell repository ( from Bitbucket:

git clone
cd bioshell

This should create bioshell directory in your current location. The second line steps into this new directory

3. Run CMake:

cd build
cmake ..

The build directory will contain compilation intermediate files and may be deleted once BioShell is compiled. The first line enters that direcotry, the second command calls cmake to set up the compilation process. CMake attempts to set up everything automatically, sometimes however it would require some guidance, e.g. to find the right compiler (see below)

4. Run Make:

make -j 4

where -j 4 allows make use 4 cores to run parallel compilations. This command will attempt to compile all targets; the list of all targets can be printed by make help. As one can see, each executable is a separate target. There are also predefined group targets:

compiles only bioshell library
compiles bioshell library and bioshell toolkit applications, such as seqc and strc
compiles all examples, i.e. all ap_ and ex_ application


Last step is to add path to data/ directory to your shell variables e.g.

export BIOSHELL_DATA_DIR="/Users/username/bioshell/data"

or add this variable to your ~/.bashrc:

echo 'export BIOSHELL_DATA_DIR="/Users/username/bioshell/data" ' >> ~/.bashrc

6. Additional parameters for compilation

The procedure described above compiles the package with the default settings: Release build with no profiling. To change it, you should remove everything from ./build directory and generate new makefiles with new settings:

  • in order to use a compiler other that the default one (e.g. gcc version 4.9), say:

    cmake -DCMAKE_CXX_COMPILER=g++-4.9  -DCMAKE_C_COMPILER=gcc-4.9 -DCMAKE_BUILD_TYPE=Release ..

or to use icc for instance:

  • to selecting a different compiler and making a profile build

  • to brew a debug build, turn -DCMAKE_BUILD_TYPE=Release into -DCMAKE_BUILD_TYPE=Debug. So to make a debug build without changing the compiler, say just:

    cmake -DCMAKE_BUILD_TYPE=Debug ..
  • to make a profiling build (-pg option) for gcc or Xcode Instruments add -D PROFILE=ON to the cmake command (the custom PROFILE variable test is implemented in the main CMakeLists.txt).

    cmake -D PROFILE=ON ..

7. Using IDE

In the above examples, cmake was used to produce makefiles for to compile BioShell. cmake command may be also used to generate project files for other environments, in particular:

  • to produce *.xcodeproj file for xcode:

    cmake  -DCMAKE_BUILD_TYPE=Release -G Xcode
  • or to prepare solution files for Microsoft Visual Studio (must be run on a Windows machine):

    cmake  -DCMAKE_BUILD_TYPE=Release -G "Visual Studio 2013"