Gromacs 2022 fiase after updating Ubuntu to 22.04

GROMACS version: 2022
GROMACS modification: No

I had installed and used GROMACS 2022 in my workstation w/o problems until I ungraded to Ubuntu 22.04.

Now if I try to run gmx I set the following error message:
gmx: /lib/x86_64-linux-gnu/libpthread.so.0: version `GLIBC_PRIVATE’ not found (required by gmx)

I tried to compile gmx 2022 again with the following cmake line:

CC=gcc CXX=g++ cmake …/ -DGMX_GPU=CUDA -DGMX_BUILD_OWN_FFTW=ON -DGMX_PREFER_STATIC_LIBS=ON -DCMAKE_BUILD_TYPE=Release -DREGRESSIONTEST_DOWNLOAD=ON -DCMAKE_INSTALL_PREFIX=/usr/local/gromacs2022_2/

cmake seems to work fine w/o Errors, but when I do the make part, after a while I set the following error message:

/usr/bin/ld: /usr/lib/x86_64-linux-gnu/libopenblas.a(sormtr.o): in function sormtr_': (.text+0x34e): undefined reference to _gfortran_concat_string’
/usr/bin/ld: (.text+0x4e7): undefined reference to _gfortran_concat_string' /usr/bin/ld: (.text+0x559): undefined reference to gfortran_concat_string’
/usr/bin/ld: (.text+0x5a9): undefined reference to _gfortran_concat_string' /usr/bin/ld: /usr/lib/x86_64-linux-gnu/libopenblas.a(sormql.o): in function sormql
’:
(.text+0x5f7): undefined reference to _gfortran_concat_string' /usr/bin/ld: /usr/lib/x86_64-linux-gnu/libopenblas.a(sormql.o):(.text+0x6be): more undefined references to _gfortran_concat_string’ follow
collect2: error: ld returned 1 exit status
make[2]: *** [src/programs/CMakeFiles/gmx.dir/build.make:100: bin/gmx] Error 1
make[1]: *** [CMakeFiles/Makefile2:6200: src/programs/CMakeFiles/gmx.dir/all] Error 2
make: *** [Makefile:166: all] Error 2

How can I fix either of these issues?

Thanks.

Raul.

Hello Raul,

Were you running CMake in a clean directory, or have you just re-run it in the old build directory? If it’s the latter, I suggest fully clearing the directory and building from scratch.

If that does not help, it looks like the problem comes from libopenblas. You can try adding -DGMX_EXTERNAL_BLAS=OFF -DGMX_EXTERNAL_LAPACK=OFF to your CMake call to build BLAS and LAPACK libraries bundled with GROMACS instead of trying to use the ones provided by the OS.