For the impatient. Must haves:
Optional:
Get, build, and test:
git clone –recursive git@b:/xpacc-dev/PlasCom2 itbu cket. org
mkdir PlasCom2/build
cd PlasCom2/build
cmake ../
make
make test
Read on as needed for details.
PlasCom2 can be obtained from the XPACC Bitbucket repository. Make sure to use the "--recursive" option when cloning the repository so that all sub-modules will be picked up. For example:
git clone –recursive git@b:/xpacc-dev/PlasCom2 [PC2SRCPATH] itbu cket. org
The above command should create a clone of the PlasCom2 repository in at your local path [PC2SRCPATH]. If [PC2SRCPATH] argument is not supplied, then the default path will be ./PlasCom2. The path to your clone of PlasCom2 will hereafter be referred to as PC2SRCPATH.
PlasCom2 uses CMake (2.8+) for configuration, and build management. It is highly recommended to create a build directory that is separate from your PlasCom2 source path (PC2SRCPATH). Typically, this is done by creating a build directory below the PC2SRCPATH. For example:
mkdir PC2SRCPATH/build && cd PC2SRCPATH/build
Regardless of where the build will be conducted, the build directory will hereafter be referred to as PC2BLDPATH. There are a few environment variables that can be helpful when configuring PlasCom2. If you do not set these environment variables, CMake will attempt to find the appropriate setup by searching your environment and common system paths. PlasCom2 requires MPI, and to ensure the correct building environment is found, it can be useful to set the following:
CC=mpicc
CXX=mpicxx
FC=mpif90
If used, the above environment variables should be set to the desired MPI compilers before invoking CMake to configure PlasCom2. In addition, if third-party packages (e.g. HDF5 and/or Cantera) are installed in non-standard, or user-owned file spaces, then CMake must be made aware of the path to those packages. The following environment variable can be used to indicate third-party or non-standard paths:
CMAKE_PREFIX_PATH=/path/to/hdf5:/path/to/cantera
CMake will search the bin, lib, share, and include subdirectories of any paths included in CMAKE_PREFIX_PATH for tools, libraries, and include files required by the build.