Installation

From stats++ wiki
Jump to: navigation, search

The following instructions detail the installation of stats++ in its two primary use-cases.

Note that stats++ (temporarily) requires the jScience library. The following detail the installation of this as well.

(Temporary) jScience

Instructions

  1. Obtain jScience (provided with stats++); instructions here.
  2. In jScience-path/:
         $ CXX=[C++ compiler] make

    where jScience-path/ is the path to jScience.

  3. Add to either .bashrc, .bash_profile, or .profile (as appropriate):
         export CPATH=jScience-path:$CPATH
         export CPATH=jScience-path/include:$CPATH
         export LIBRARY_PATH=jScience-path:$LIBRARY_PATH

    where jScience-path/ is the full path to jScience.

Header-only Library

stats++ is fundamentally a header-only library.

Irrespective of its end use, stats++ must be available in this format.

Instructions

  1. Obtain stats++; instructions here.
  2. Add to either .bashrc, .bash_profile, or .profile (as appropriate):
         export CPATH=statsxx-path:$CPATH

    where statsxx-path/ is the full path to stats++.

Executable

Several of the (major) features of stats++ are available as (buildable) executables.

Instructions

  1. (Recommended) Create a top-level directory in which to contain stats++ executables (statsxx-build-tld-path).
  2. Create a directory to build the executable (statsxx-build-exe-path) (recommended: in statsxx-build-tld-path/).
  3. In statsxx-build-exe-path/:
         $ CXX=[C++ compiler] cmake statsxx-exe-path
         $ make

    where statsxx-exe-path/ is the path to the executable code of stats++ that you want to build.

  4. Add to either .bashrc, .bash_profile, or .profile (as appropriate):
         export PATH=statsxx-build-exe-path:$PATH