This repository contains a standalone implementation of
the GFN0-xTB method (https://doi.org/10.26434/chemrxiv.8326202.v1),
adapted from the xtb code.
The default CMake and meson builds compile a statically linked library (libgfn0.a) that can be linked in other projects.
main.f90 in testprog/ demonstrates the in-code usage.
Make sure you have the following dependencies installed:
- CMake and
make, or meson and ninja build systems - Fortran and C compilers (e.g.,
gfortran/gccorifort/icc)
Follow these steps to build the project:
-
Create a build directory and navigate to it
mkdir _build cd _build -
Export the compilers (here for example
ifort/icc) and depending on your chosen build system set up the build:- generate the build files using CMake:
FC=ifort CC=icc cmake ..
- generate the build files using meson:
FC=ifort CC=icc meson ..
I you wish to build the test-binary, add
-Dbuild_exe=trueto either thecmakeormesonsetup command. - generate the build files using CMake:
-
Depending on your chosen build system, build the project. If you have multiple cores/processors, you can speed up the build process by specifying the number of cores to use with the
-joption. For example, to use 4 cores:- With CMake/
make:make -j4
- With meson/
ninja:ninja -j4
- With CMake/
To clean the build files, simply delete the build directory:
rm -rf _build