Error in compiling Cp2k with PLUMED

50 views
Skip to first unread message

Rajorshi Chattopadhyay

unread,
Apr 14, 2023, 1:22:20 PM4/14/23
to cp...@googlegroups.com
Hello all,

I am trying to compile CP2k-9.1 with PLUMED 2.8.2. I could install PLUMED separately, but when I try to compile CP2k with PLUMED, I get the following error:
 

/usr/bin/ld: /home/rajorshi/cp2k-9.1/tools/toolchain/install/libxsmm-1.17/lib/libxsmm.a(libxsmm_malloc.o): in function `libxsmm_xget_scratch_allocator':

libxsmm_malloc.c:(.text.libxsmm_xget_scratch_allocator+0x111): undefined reference to `pthread_yield'

/usr/bin/ld: /home/rajorshi/cp2k-9.1/tools/toolchain/install/libxsmm-1.17/lib/libxsmm.a(libxsmm_malloc.o): in function `libxsmm_xrelease_scratch':

libxsmm_malloc.c:(.text.libxsmm_xrelease_scratch+0x101): undefined reference to `pthread_yield'

/usr/bin/ld: /home/rajorshi/cp2k-9.1/tools/toolchain/install/libxsmm-1.17/lib/libxsmm.a(libxsmm_main.o):libxsmm_main.c:(.text.libxsmm_finalize+0xf1): more undefined references to `pthread_yield' follow

collect2: error: ld returned 1 exit status

make[3]: *** [/home/rajorshi/cp2k-9.1/obj/local/ssmp/all.dep:150: /home/rajorshi/cp2k-9.1/exe/local/grid_unittest.ssmp] Error 1

make[2]: *** [/home/rajorshi/cp2k-9.1/Makefile:158: all] Error 2

make[1]: *** [/home/rajorshi/cp2k-9.1/Makefile:140: ssmp] Error 2

make[1]: *** Waiting for unfinished jobs....

make[2]: *** [/home/rajorshi/cp2k-9.1/Makefile:158: all] Error 2

make[1]: *** [/home/rajorshi/cp2k-9.1/Makefile:140: sdbg] Error 2

make: *** [Makefile:135: all] Error 2


I find that the libxsmm library was installed successfully in the previous step. 
I have attached the entire output of make and the arch file for reference. 
--
With Regards,
Rajorshi Chattopadhyay,
PhD Researcher in Mineralogy/Crystallography,
Institut für Geologie und Mineralogie,
Universität zu Köln, Germany

local.ssmp
make.log

Rajorshi Chattopadhyay

unread,
Apr 14, 2023, 7:06:58 PM4/14/23
to cp...@googlegroups.com
Hello all,

To provide some more information, I am trying to compile cp2k.ssmp and cp2k.sdbg with PLUMED. I have configured PLUMED with the disabled mpi option.

Krack Matthias

unread,
Apr 15, 2023, 3:13:00 PM4/15/23
to cp...@googlegroups.com

Hi

 

Did you try to add the linker flag “-lpthread”.

 

HTH

 

Matthias

--
You received this message because you are subscribed to the Google Groups "cp2k" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cp2k+uns...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/cp2k/CACTJSRcWQSW-ZCHy2bcZ9Yg%2B57fo0tVJ8jxXwLc%2BF8u3JEjUiA%40mail.gmail.com.

Rajorshi Chattopadhyay

unread,
Apr 15, 2023, 4:05:15 PM4/15/23
to cp...@googlegroups.com
Hi,

The -lpthread linker flag was already there in the arch file produced by CP2k after the library installation step via the toolchain script. I also checked that the path to libpthread is in the LIBRARY_PATH environment variable.

Reply all
Reply to author
Forward
0 new messages