Basic compilation

To compile a program (source file biohello.cpp) using Bio++, you need to link the libraries.

What you need to use Bio++
Basically, you need a C++ compiler with STL (Standard Template Library) support, and a text editor. You will need to extract the downloaded archives. Linux comes with the appropriate tools, you will need to install some software under windows (eg 7-zip). You may find useful to use an IDE (Integrated Development environment), particularly under windows.

If you want to retrieve the source from CVS, you'll need a CVS client. From version 1.9.0, bio++ uses the cmake building tool. If it is not directly available on your system, you can download it from here.

Dynamic linkage
Programs compiled with dynamic linkage will not run without the libraries. Libraries must be in the same path than the path used for compilation.

The -I and -L options are needed only if you installed the libraries in a non-standard place. Here the five libraries are included, you may omit the two last ones if you do not use phylogenetic and/or population genetics classes.

Static linkage
Programs compiled with static linkage are stand-alone programs and do not require the libraries to be present when running. This is the only linkage available under cygwin.

When compiling with static linkage, the order of the libraries to include is important: Here again you may omit the PopGen and Phyl libraries. The strip command removes all unused code from the executable, and efficiently decreases its size.