# potfit wiki

open source force-matching

### Sidebar

User Guide

Examples

Potential Databases

More

compiling:make

# Compiling potfit using make

Info: Although potfit still supports using make as a build system it is recommended to use the waf build system as it fixes several issues present with make.

potfit can be compiled with GNU make, which we call gmake in the following. Note that on most systems, GNU make is called make. Most other implementations of make won't work.

gmake [FLAGS="some flags"] potfit-target

The compiler and compilation flags are determined according to the SYSTEM variable, which has to be set once in the Makefile.inc on line 113.

Further compile or link flags, in addition to those determined by the SYSTEM variable, can be passed on the command line with the help of the FLAGS environment variable.

After compiling, the potfit executable is moved to the directory \$HOME/bin, if it exists. Otherwise it is not moved. The location where executables are put can also be customized in src/Makefile (line 40, BIN_DIR variable).

potfit-target consists of several components and has the following structure:

 potfit[_parallelization][_option][_option]...

Most features of potfit must be activated with the corresponding compilation option in the make target. The most important option is the interaction you want to use. Most options can coexist with each other.

Here are some examples that might help you compile potfit.

#### Compilation Options

The compilation options are described together with the simulation features they enable. For details, see the main.

#### Supported values of the ''SYSTEM'' variable

Currently, the following values of the SYSTEM variable are supported and properly tested:

x86_64-gcc 	All recent 64 bit processors, gcc
x86_64-clang 	All recent 64 bit processors, clang
x86_64-icc 	All recent 64 bit processors, icc

The following values of the SYSTEM variable are also available but not very well tested:

i686-gcc 	32 bit processor, gcc
i686-icc 	32 bit processor, icc

Support for different values of SYSTEM is easily added. The Makefile contains a detailed decsription of how the compile and link flags are determined from a number of Makefile variables, which has to be set for each supported value of SYSTEM. There is a template from which one can start.

#### Problems with the Intel Math Kernel Library

If you are having trouble linking potfit with the Intel MKL, please take a look at the MKL Link Line Advisor. Replace the LIBS variable in your profile by the output of the advisor.

compiling/make.txt · Last modified: 2018/09/19 17:49 by daniel