[gmx-users] Problems with CMake and shared libraries

Justin A. Lemkul jalemkul at vt.edu
Mon Sep 6 17:37:02 CEST 2010

Hi All,

I've discovered a new problem when using CMake.  To recap, the system in
question is a PowerPC cluster running Yellowdog Linux with OpenMPI-1.4.2 and
gcc-4.2.2, linking against FFTW 3.0.1.

I gave the following commands to build mdrun with CMake:

cmake ../gromacs-4.5.1

make mdrun

make install-mdrun

When attempting to invoke the resulting "mdrun_4.5.1_cmake_mpi" executable, I
get the following error:

/home/rdiv1001/gromacs-4.5.1_cmake-linux/bin/mdrun_4.5.1_cmake_mpi: error while
loading shared libraries: libgmxpreprocess_mpi.so.6: cannot open shared object
file: No such file or directory

Adding -DBUILD_SHARED_LIBS=OFF solves the problem.  Since (by default) Gromacs
builds shared libraries, I thought this little problem should be reported, even
though I can work around it.  The cmake and subsequent make steps reported no
problems whatsoever beyond a couple of minor compiler warnings, so I assumed
that everything had gone well.



Justin A. Lemkul
Ph.D. Candidate
ICTAS Doctoral Scholar
Department of Biochemistry
Virginia Tech
Blacksburg, VA
jalemkul[at]vt.edu | (540) 231-9080


More information about the gromacs.org_gmx-users mailing list