Rate This Document
Findability
Accuracy
Completeness
Readability

Different Compilers Are Linked to Different OpenMP Runtime Libraries

Error Information

  • A test error is reported.
  • The OpenMP runtime library cannot be loaded.

Problem

The OpenMP runtime library linked to executable programs compiled by Clang is libomp.so, and that linked to executable programs compiled by GCC is libgomp.so.

Solution

Ensure that libomp.so can be found.

  • Add the directory where libomp.so is located (for example, {$INSTALLATION_HOME}/lib, where INSTALLATION_HOME indicates the installation root directory) to the environment variable LD_LIBRARY_PATH.
  • Alternatively, install libomp.
    1
    yum install libomp -y