Skip to content
Thomas Bigot edited this page Feb 23, 2014 · 12 revisions

INSTALLATION

INTRODUCTION

This help file explains how to do with the files you’ve downloaded. It also describe the procedure to build the program from sources. If you think your technical skills are not sufficient to choose the appropriate procedure, just take the "suggested" choices.

INSTALLATION FROM SOURCE (Suggested Choice)

GENERAL REQUIREMENTS

WHAT DO YOU NEED

tpms requires several softwares or libraries. Unless you need it, we advise you not to install these softwares from sources but from packages of your distribution.

  • a compilation environment, typically gcc, the Gnu Compiler Collection, with gcc-c++
  • CMake, a cross-platform system for build automation (http://www.cmake.org/)
  • some libraries, and their development files (devel packages or installation with sources):

HOW TO INSTALL THE REQUIREMENTS

Linux distributions

Typically, on a package based linux distribution, you will have to install all bpp & bpp-devel packages, and libboost & libboost-devel packages.

Boost is included in most of linux distributions. If you don't know which packages to install, just launch you package manager, perform a search on "boost", and select a package containing "devel", typically "lib64boost-devel". This package will probably trigger (thanks to the package dependencies system) the installation of all the needed boost package. You can find help on your distribution community website, forums, or wiki.

Bio++ is not included in all distributions (for the moment, only Debian). You will have to go to the website (http://biopp.univ-montp2.fr/), go to the download section (http://biopp.univ-montp2.fr/articles/download/index.html#linux), and install packages.

Mac OS

You'll have to download bio++ and boost sources, compile them:

Bio++ is here: http://biopp.univ-montp2.fr/Repositories/sources/. Download and install these packages (in this order):

  • bpp-core
  • bpp-seq
  • bpp-phyl
  • bpp-raa (if you want to build your own collection)

Boost is here: http://www.boost.org/users/download/ (you can use MacPort - sudo port install boost)

Please refer to each program documentation.

GET TPMS SOURCES

FROM TPMS WEBSITE

Go to: ftp://pbil.univ-lyon1.fr/pub/mol_phylogeny/tpms/ and get the last version of tpms-source.

DEVELOPMENT VERSION OF TPMS

If you want to test last features of tpms, you may download the development version on github. Use the command:

git clone git://github.com/tbigot/tpms.git

COMPILATION

PREPARING COMPILATION WITH CMAKE

If you have already compiled a program from sources, you probably know the command "./configure". CMake is a more modern and cross-platform equivalent. Its aim is to prepare compilation and check every requirement is installed and found. You just have to go to the main directory of tpms and type:

cmake .

(do not forget the final period). You're supposed to get a text similar to:

-- Library BPP found here:
includes : /usr/include/
libraries: /usr/lib/
-- Boost version: 1.40.0
-- Found the following Boost libraries:
--   filesystem
--   system
-- Configuring done
-- Generating done
-- Build files have been written to: /home/you/tpms

COMPILATION

You will need to compile two binaries. tpms_mkdb to create your collection file (if you don't yet have a database in the RAP format), tpms_query to query your database, and tpms_computations to perform other operations on your collections. You just have to type:

make tpms_query make tpms_mkdb make tpms_computations

You'll get messages such as:

[...]
Linking CXX executable build/tpms_mkdb

which means your binary is done and available in the directory "build/".

INSTALLATION

Note it's not an obligation to install tpms. You can let the binary files in their directory ("build/") and then launch them from this directory. But if you want to be able to launch tpms programs from everywhere, you can follow these instructions below.

There is not yet an automatic way to install tpms. But it's quite simple: you just have to copy binary files (tpms_query and tpms_mkdb) from "build/" directory to a directory which is in your PATH environment variable. Eg: /usr/local/bin/

You can now use the program, feel free to skip to the last part “After installation”.

AFTER INSTALLATION

You can now use tpms. In the tpms_mkdb help file, you will find explanations the next step: how to create your own collection, and the tpms_query and tpms_computations will let you know how to perform queries and operations on your collection files.

UNSUPPORTED (for achive): INSTALLING BINARIES (Unsupported for now)

BACKGROUND

You've dowloaded a binary version of tpms, and you want to know how to install it on a system.

LINUX

With the linux operating system, you have the choice between dynamic and static version. If you are running on a standalone computer, and never heard anything about libraries, ie. you just want it to work, we suggest to choose the static version.

Choose between Static or Dynamic version (according to which file you have dowloaded).

Static version (Suggested choice)

Static version "just works" because the binary file (the program) includes all needed libraries. You have to extract the archive file you downloaded, and you will find binary files. You can put these files anywhere on your system, and call them typing the full path to access them. Or you can copy them in a directory that is in your PATH variable, for instance /usr/local/bin on most linux distributions. Then, you will be able to directly call the binary, without the complete path.

You can now use the program, feel free to skip to the last part “After installation”.

Dynamic version

Dynamic binaries is probably technically a better choice: less memory used (dynamic libraries are loaded once, then shared between all processus linked to them), more maintainable: you can updates the libraries only, if a bug is corrected (provided the version change does not break the API)

You have to install some libraries, but don’t need to install devel packages:

  • boost (included in most distributions) version ≥ 0.48:
    • boost-filesystem
    • boost-threads
    • boost-system

Bio++ version 2.0.3 (RPMs and DEBs are available here: http://biopp.univ-montp2.fr/articles/download/index.html#linux):

  • bpp-core
  • bpp-seq
  • bpp-phyl you don't need any -devel package.

Then, you can use the binaries provided by the archive of tpms. Feel free to use it "as is" in your home directory or to copy the binary files in a directory that is in your path, eg: /usr/local/bin

You can now use the program, feel free to skip to the last part “After installation”.

MAC OS

In the Mac OS package, there is a directory called "program". In this directory, you'll find the binary files (the programs) beginning with "tpms_" and the libraries beginning with "lib". You can use the binaries "as is" letting all files in the same directory. If you want to install, it's quite easy, just type this in your terminal:

cd <directory in which you extracted tpms>/program
cp tpms_* /usr/local/bin
cp *dylib /usr/local/lib

You can now use the program, feel free to skip to the last part “After installation”.