A fast and precise DFT wavelet code

Prepare the environment

A fast and precise DFT wavelet code
Jump to: navigation, search

Running and postprocessing results with BigDFT suite

After successful compilation of BigDFT suite, while trying to run the code, you might have experienced errors like the following:

./bigdft: error while loading shared libraries: [...]: cannot open shared object file: No such file or directory

or, while trying to execute make check or similar commands, errors like

In reference file: 'module' object has no attribute ‘CLoader’

This means that either

  • Some of the submodules of BigDFT were compiled with invalid options (unfortunately the solution to this problem should be found on a case-by-case scenario);
  • The environment variables of the shell in which you are running are not correctly set.

The latter situation is of course solvable, but it might require extra knowledge about the position of the shared libraries, the python site-packages and so on. So in case you do not want to bother with problems of LD_LIBRARY_PATH and PYTHONPATH we have created a script, called bigdftvars.sh that should be sourced (or otherwise executed in some platforms) to set these variables.

Such a script might be found close to the position of bigdft executable (<builddir>/install/bin in the common situation), depending on the prefix you choose for the installation. To see what it does, here you might find an example on how to use it:

> cd <builddir>/install/bin/
> source ./bigdftvars.sh

the output should be similar to the following:

While sourcing this script the following environment variable will be set:
export LD_LIBRARY_PATH=/local/binaries/gfortran-fpe-1.8/install/lib ;
export PYTHONPATH=/local/binaries/gfortran-fpe-1.8/install/lib/python2.7/site-packages ;
export BIGDFT_ROOT=/local/binaries/gfortran-fpe-1.8/install/bin ;
export GI_TYPELIB_PATH=/local/binaries/gfortran-fpe-1.8/install/lib/girepository-1.0 ;

The actual variable that will be charged would depend on

  • The actual options of your installation procedure;
  • Whether or not the related variable are already correctly set on your machine (yes yes the script tests it).

So to test if everything is ok you might do the procedure another time and see that this time the script does not announce any modifications:

> source ./bigdftvars.sh
While sourcing this script the following environment variable will be set:

The script is written such as to be compliant either with bash or csh shells. Note that on some platforms it might be necessary to execute the script by typing "sh" instead of "source". In any case, to verify that everything is OK it is advised to to the procedure twice to see that the second execution is shallow.

Personal tools