[gmx-users] Problems with CMake and shared libraries

Szilárd Páll szilard.pall at cbr.su.se
Mon Sep 6 20:32:10 CEST 2010


Hi,

Indeed, the custom cmake target "install-mdrun" was designed to only
install the mdrun binary and it does not install the libraries this is
linked against when BUILD_SHARED_LIBS=ON.

I'm not completely sure that this is actually a bug, but to me it
smells like one. I'll file a bug report and will sort this issue out.

Thanks Justin for reporting!

Cheers,
--
Szilárd



On Mon, Sep 6, 2010 at 5:37 PM, Justin A. Lemkul <jalemkul at vt.edu> wrote:
>
> 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
> -DFFTW3F_LIBRARIES=/home/rdiv1001/fftw-3.0.1-linux/lib/libfftw3f.so
> -DFFTW3F_INCLUDE_DIR=/home/rdiv1001/fftw-3.0.1-linux/include/
> -DCMAKE_INSTALL_PREFIX=/home/rdiv1001/gromacs-4.5_cmake-linux
> -DGMX_BINARY_SUFFIX=_4.5_cmake_mpi –DGMX_THREADS=OFF –DGMX_X11=OFF
> -DGMX_MPI=ON
> -DMPI_COMPILER=/home/rdiv1001/compilers/openmpi-1.4.2/bin/mpicxx
> -DMPI_INCLUDE_PATH=/home/rdiv1001/compilers/openmpi-1.4.2/include
>
> 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
>
> --
> ========================================
>
> Justin A. Lemkul
> Ph.D. Candidate
> ICTAS Doctoral Scholar
> MILES-IGERT Trainee
> Department of Biochemistry
> Virginia Tech
> Blacksburg, VA
> jalemkul[at]vt.edu | (540) 231-9080
> http://www.bevanlab.biochem.vt.edu/Pages/Personal/justin
>
> ========================================
>
> --
> gmx-users mailing list    gmx-users at gromacs.org
> http://lists.gromacs.org/mailman/listinfo/gmx-users
> Please search the archive at http://www.gromacs.org/search before posting!
> Please don't post (un)subscribe requests to the list. Use the www interface
> or send it to gmx-users-request at gromacs.org.
> Can't post? Read http://www.gromacs.org/mailing_lists/users.php
>



More information about the gromacs.org_gmx-users mailing list