error in cp2k compilation
gooaah opened this issue · 5 comments
I'm trying to compile cp2k. I use Intel 2018u4 and gcc 8.2, the cp2k is in the master branch. When I run
./configure-libint-skx-gnu.sh
for libint, it reports:
...
Skipping ./src/lib/libint/Makefile
Skipping ./src/lib/libr12/Makefile
configure: creating ./config.status
./configure: line 16238: : command not found
./configure: line 16238: no: command not found
./configure: line 16238: : command not found
./configure: line 16238: : command not found
./configure: line 16238: x86_64-unknown-linux-gnu: command not found
./configure: line 16238: : command not found
./configure: line 16238: linux-gnu: command not found
./configure: line 16238: : command not found
./configure: line 16238: : command not found
./configure: line 16238: x86_64-unknown-linux-gnu: command not found
./configure: line 16238: : command not found
./configure: line 16238: linux-gnu: command not found
./configure: line 16238: : command not found
Usage: /usr/bin/grep [OPTION]... PATTERN [FILE]...
Try '/usr/bin/grep --help' for more information.
./configure: line 16238: : command not found
./configure: line 16238: /usr/bin/grep -E: No such file or directory
../configure: line 16238: : command not found
./configure: line 16238: ln -s: command not found
./configure: line 16238: : command not found
./configure: line 16238: o: command not found
./configure: line 16238: : command not found
/usr/bin/ar: no operation specified
Usage: ranlib [options] archive
Generate an index to speed access to archives
The options are:
@ Read options from
--plugin Load the specified plugin
-D Use zero for symbol map timestamp
-U Use actual symbol map timestamp (default)
-t Update the archive's symbol map timestamp
-h --help Print this help message
-v --version Print version information
ranlib: supported targets: elf64-x86-64 elf32-i386 elf32-iamcu elf32-x86-64 a.out-i386-linux pei-i386 pei-x86-64 elf64-l1om elf64-k1om elf64-little elf64-big elf32-little elf32-big plugin srec symbolsrec verilog tekhex binary ihex
./configure: line 16238: : command not found
gcc: fatal error: no input files
compilation terminated.
./configure: line 16238: : command not found
./configure: line 16238: -O3 -mavx512f -mavx512cd -mavx512dq -mavx512bw -mavx512vl -mfma : command not found
...
Then I use configure-libint-hsw-gnu.sh
, the compilation is successful. But when I run the cp2k exe file, it reports:
Program received signal SIGILL: Illegal instruction.
Backtrace for this error:
#0 0x2b6ce27cc27f in ???
#1 0x2a49e52 in ???
#2 0x408a8c in ???
#3 0x2b6ce27b83d4 in ???
#4 0x408abc in ???
#5 0xffffffffffffffff in ???
Illegal instruction
CP2K's master changed to LIBINT v2 (and beyond). This change just settled this week. Here are my comments: (1) XCONFIGURE is not ready yet for CP2K/master as I haven't learned myself yet how the new LIBINT goes and what the tuning points are, (2) Be careful in general when using any of the master revisions whether it's cp2k/master or even CP2K/hfp/master.
I recommend following the step-by-step guide for CP2K 6.1.
I realize that you just wanted to configure LIBINT. I will look at the lines in configure
to check which tools are missing. As said before, this LIBINT1 will not work with CP2K/master, you may rely on CP2K 6.1 for the time being. The error pointed out in your details looks like you are missed to install some packages on your system, but that is just a guess until I can look closer at the issue.
[...] ./configure: line 16238 [...]
I am using LIBINT 1.1.6, which is the latest possible version for CP2K 6.1 (or even CP2K/master until recently). For me, the configure
script as contained in the libint 1.1.6 archive (and called by the XCONFIGURE wrapper scripts) only has 6335 lines. I will ignore this issue for now.
Program received signal SIGILL: Illegal instruction.
This seems to be an unclean build of CP2K, which still uses some obj-file (.o
) that came from your originally intended configuration. Within the CP2KROOT directory, perhaps try rm -rf exe lib obj
.
Thanks for your help. I find the reason of failure is that the machine does not support AVX3. I use configure-libint-hsw-gnu.sh
and then compile cp2k with AVX=1
. The cp2k can run correctly.
Thank you for following up and sharing the final status! Indeed, LIBINT1 never properly supported cross-compilation i.e., the system building the library required to have at least the CPU-features of the intended target. This caused constant issues with cluster systems using an older head-node system when compared to the cluster's compute-nodes.
I am looking forward to LIBINT2 to be used in CP2K 7.1 release. In fact, your issue report triggered some (still early) preparation for LIBINT2 on my side.
Thank you for using XCONFIGURE,
and for your report!