All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Installation
O2scl installation is generally the same as that for other GNU libraries. The file INSTALL has some details on this procedure. Generally, you should be able to run ./configure and then type make and make install. More information on the configure command can also be obtained from ./configure –help. O2scl requires Boost and the GSL library. If the configure script cannot find Boost or GSL, you may have to specify their location in the CPPFLAGS and LDFLAGS environment variables (./configure –help shows some information on this). The documentation is included in the distribution and automatically installed by make install.

After make install, you may test the library with make o2scl-test. At the end, the phrase All O2scl tests passed indicates that the testing was successful. You may also run make o2scl-test in the individual subdirectories of the src directory to individually test the classes and functions in that part of O2scl . Note that make check will not work. The testing code in src/base/lib_settings_ts.cpp can be useful in finding out how O2scl was compiled. After make o2scl-test, running src/base/lib_settings_ts will output several of the installation settings.

This library requires GSL and is designed to work with GSL versions 1.16 or greater, which can be obtained from http://www.gnu.org/software/gsl . Some classes may work with older versions of GSL, but this cannot be guaranteed. A CBLAS library is also required, and ./configure will look for libcblas first, and if not found then it will look for libgslcblas. If neither is present, then you may have to manually specify a CBLAS library using the LIBS and LDFLAGS environment variables.

Most classes and functions which require linear algebra can be used with the Eigen (http://eigen.tuxfamily.org) or Armadillo (http://arma.sourceforge.net) vector and matrix objects. This can be specified in the configure command with –enable-armadillo or –enable-eigen. Note that the O2scl classes which use Armadillo use matrix decompositions so Armadillo must be compiled with LAPACK support, and you may need to specify the location of the LAPACK libraries manually.

File I/O is handled using the HDF5 library, which can be obtained from http://www.hdfgroup.org . To compile O2scl without HDF support, use the argument –disable-hdf to configure during installation. If HDF5 is not located in a typical location for your system, in order to compile O2scl with HDF support you may have to specify the location of the HDF header files and libraries with the -I and -L flags. Some O2scl functions use the high-level HDF routines found in the hdf5_hl library, but this library is usually in the same location as the base hdf5 library.

O2scl assumes some c++11 support, and if this is not available, then the user should give the –disable-cpp11 flag to the configure script and -DO2SCL_NO_CPP11 should be defined when using O2scl header files. You may have to add a flag to compile with c++11 support to your compiler, e.g. -std=c++0x.

Range-checking for vectors and matrices is turned on by default. You can disable range-checking by defining -DO2SCL_NO_RANGE_CHECK, e.g.

CPPFLAGS="-DO2SCL_NO_RANGE_CHECK" ./configure

The separate libraries O2scl_eos and O2scl_part are installed by default. To disable the installation of these libraries and their associated documentation, run ./configure with the flags –disable-eoslib or –disable-partlib. Note that O2scl_eos depends on O2scl_part so using –disable-partlib without –disable-eoslib will not work. Note also that both O2scl_part and O2scl_eos require HDF5 support.

There are several warning flags that are useful when configuring and compiling with O2scl . See the GSL documentation for an excellent discussion, and also see the generic installation documentation in the file INSTALL in the O2scl top-level directory. For running configure, for example, if you do not have privileges to write to /usr/local,

CPPFLAGS="-O3 -I/home/asteiner/install/include" \
LDFLAGS="-L/home/asteiner/install/lib" ./configure -C \
--prefix=/home/asteiner/install

In this example, specifying -I/home/asteiner/install/include and -L/home/asteiner/install/lib above ensures that the GSL libraries can be found (this is where they are installed on my machine). The –prefix=/home/asteiner/install argument to ./configure ensures that O2scl is installed there as well.

For those users wanting to compile O2scl under Xcode on a Mac, some advice for doing this has been posted to the o2scl-help mailing list.

The O2scl documentation is generated with Doxygen . In principle, the documentation can be regenerated by the end-user, but this is not supported and requires several external applications not included in the distribution.

Un-installation: While there is no explicit "uninstall" makefile target, there are only a couple places to check. Installation creates directories named o2scl in the include, doc and shared files directory (which default to /usr/local/include, /usr/local/doc, and /usr/local/share) which can be removed. Finally, all of the libraries are named with the prefix libo2scl and are created by default in /usr/local/lib. As configured with the settings above, the files are in /home/asteiner/install/include/o2scl, /home/asteiner/install/lib, /home/asteiner/install/share/o2scl, and /home/asteiner/install/doc/o2scl.

Documentation generated with Doxygen. Provided under the GNU Free Documentation License (see License Information).
Hosted at Get Object-oriented Scientific Computing
Lib at SourceForge.net. Fast, secure and Free Open Source software
downloads..