<div dir="ltr">Hey! So I have a working version of cp2k.psmp on my KNL machine finally. Now I would like to build with elpa. <div>However it fails. Any ideas would be greatly appreciated.</div><div><br></div><div>Ron</div><div><br></div><div>detail:</div><div><br></div><div><br></div><div>Simply using: <div>./install_cp2k_toolchain.sh  --with-libint=install  --with-gcc=install --with-sirius=no --with-libxc=install --with-elpa=install</div><div>failed in the elpa build with no useful message.</div><div><br></div><div>So I configured elpa by hand for gnu and modified install_elpa.sh as follows:</div><div><br></div><!--?xml version="1.0" encoding="UTF-8"?-->

<div>lpa_ver=${elpa_ver:-2017.05.002}
</div><div>source "${SCRIPT_DIR}"/common_vars.sh
</div><div>source "${SCRIPT_DIR}"/tool_kit.sh
</div><div>source "${SCRIPT_DIR}"/signal_trap.sh
</div><div>SCALAPACK_LDFLAGS="-L$MKL_HOME/lib/intel64 -lmkl_scalapack_lp64 -lmkl_gf_lp64 -lmkl_sequential \
</div><div>                             -lmkl_core -lmkl_blacs_intelmpi_lp64 -lpthread -lm -Wl,-rpath,$MKL_HOME/lib/intel64"
</div><div>SCALAPACK_FCFLAGS="-L$MKL_HOME/lib/intel64 -lmkl_scalapack_lp64 -lmkl_gf_lp64 -lmkl_sequential \
</div><div>                     -lmkl_core -lmkl_blacs_intelmpi_lp64 -lpthread -lm -I$MKL_HOME/include/intel64/lp64"
</div><div><br></div><div>with_elpa=${1:-__INSTALL__}
</div><div><br></div><div>[ -f "${BUILDDIR}/setup_elpa" ] && rm "${BUILDDIR}/setup_elpa"
</div><div><br></div><div>ELPA_CFLAGS='-mavx512f -mavx512er -mavx512cd -mavx512pf '
</div><div>ELPA_LDFLAGS='-L$MKL_HOME/lib/intel64 -lmkl_scalapack_lp64 -lmkl_gf_lp64 -lmkl_sequential \
</div><div>                             -lmkl_core -lmkl_blacs_intelmpi_lp64 -lpthread -lm -Wl,-rpath,$MKL_HOME/lib/intel64'
</div><div>ELPA_LIBS='-L$MKL_HOME/lib/intel64 -lmkl_scalapack_lp64 -lmkl_gf_lp64 -lmkl_sequential \
</div><div>                     -lmkl_core -lmkl_blacs_intelmpi_lp64 -lpthread -lm -I$MKL_HOME/include/intel64/lp64'
</div><div>ELPA_CFLAGS_OMP='-fopenmp'
</div><div>ELPA_LIBS_OMP=''
</div><div>! [ -d "${BUILDDIR}" ] && mkdir -p "${BUILDDIR}"
</div><div>cd "${BUILDDIR}"</div><div><br></div><div>and then the toolchain ran and said it built elpa.</div><div><br></div><div><br></div><div><div><br></div></div><div><br></div><div>Then I tried the make of local.psmp and it makes it almost to the end, and fails on the link :</div><div><br></div><div><div><br></div><div><div><div>/usr/bin/ld: /home/rcohen/CP2K/cp2k/tools/toolchain/install/scalapack-2.0.2/lib/libscalapack.a(dgebs2d_.o)(.text+0xb7): unresolvable R_X86_64_32 relocation against symbol `BI_AuxBuff'</div><div>/usr/bin/ld: final link failed: Nonrepresentable section on output</div><div>collect2: error: ld returned 1 exit status</div></div><div><br></div></div><div>or in detail ((I tried adding the -no-pie but it failed the same way as without):</div><div><br></div><div><br></div><div>mpif90 -no-pie -mavx512f -mavx512er -mavx512cd -mavx512pf -march=native -fno-omit-frame-pointer -g  -O3 -funroll-loops -ffast-math  -fopenmp -I/home/rcohen/CP2K/cp2k/tools/toolchain/build  -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/mpich-3.2.1/include'  -m64 -I/mnt/beegfs/intel/compilers_and_libraries_2018.5.274/linux/mkl/include -I/mnt/beegfs/intel/compilers_and_libraries_2018.5.274/linux/mkl/include/fftw -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/fftw-3.3.7/include' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libint-1.1.6/include' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxc-4.0.3/include' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxsmm-1.10.0/include' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/elpa-2017.05.002/include/elpa_openmp-2017.05.002/modules' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/elpa-2017.05.002/include/elpa_openmp-2017.05.002/elpa' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/gsl-2.5/include' -I/home/rcohen/CP2K/cp2k/tools/toolchain/install/spglib-1.10.4/include -I/home/rcohen/CP2K/cp2k/tools/toolchain/install/hdf5-1.10.4/include -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/json_fortran-6.9.0/include' -ffree-form -std=f2003 -fimplicit-none  -Werror=aliasing -Werror=ampersand -Werror=c-binding-type -Werror=intrinsic-shadow -Werror=intrinsics-std -Werror=line-truncation -Werror=tabs -Werror=target-lifetime -Werror=underflow -Werror=unused-but-set-variable -Werror=unused-variable -Werror=unused-dummy-argument -Werror=conversion -Werror=zerotrip -Werror=uninitialized -Wno-maybe-uninitialized -Wuse-without-only  -D__LIBXSMM  -D__parallel  -D__FFTW3  -D__LIBINT -D__LIBINT_MAX_AM=6 -D__LIBDERIV_MAX_AM1=5 -D__LIBXC -D__SCALAPACK -D__ELPA=201705 -D__GSL -D__SPGLIB -D__HDF5 -D__JSON   -D__COMPILE_ARCH="\"local\"" -D__COMPILE_DATE="\"Mon Jan 14 14:15:43 CET 2019\"" -D__COMPILE_HOST="\"tomcat3\"" -D__COMPILE_REVISION="\"git:89b110c40\"" -D__DATA_DIR="\"/home/rcohen/CP2K/cp2k/data\"" -no-pie -Wl,--enable-new-dtags -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/mpich-3.2.1/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/mpich-3.2.1/lib'  -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/fftw-3.3.7/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/fftw-3.3.7/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libint-1.1.6/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/libint-1.1.6/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxc-4.0.3/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxc-4.0.3/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxsmm-1.10.0/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxsmm-1.10.0/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/scalapack-2.0.2/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/scalapack-2.0.2/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/elpa-2017.05.002/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/elpa-2017.05.002/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/gsl-2.5/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/gsl-2.5/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/spglib-1.10.4/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/spglib-1.10.4/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/hdf5-1.10.4/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/hdf5-1.10.4/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/json_fortran-6.9.0/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/json_fortran-6.9.0/lib' -L/home/rcohen/CP2K/cp2k/lib/local/psmp -o /home/rcohen/CP2K/cp2k/exe/local/cp2k_shell.psmp cp2k_shell.o  -lcp2kstart -lcp2kmc -lcp2kswarm -lcp2kmotion -lcp2kthermostat -lcp2kemd -lcp2ktmc -lcp2kmain -lcp2kgrid -ldbcsrarnoldi -ldbcsrx -lcp2kshg_int -lcp2keri_mme -lcp2kminimax -lcp2khfxbase -lcp2ksubsys -lcp2kxc -lcp2kao -lcp2kinput -lcp2kpw -lcp2kfft -lcp2kfm -lcp2kcommon -lcp2kmpiwrap -lcp2kbase -L/home/rcohen/CP2K/cp2k/lib/local/psmp/exts/dbcsr -ldbcsr -ljsonfortran -lhdf5 -lsymspg -lgsl -lgslcblas -lelpa_openmp -lscalapack -lxsmmf -lxsmm -ldl -lpthread -lxcf03 -lxc -Wl,-Bstatic -lderiv -lint -Wl,-Bdynamic -lfftw3 -lfftw3_omp  -lmpi -lmpicxx  -Wl,--start-group /mnt/beegfs/intel/compilers_and_libraries_2018.5.274/linux/mkl/lib/intel64/libmkl_gf_lp64.a /mnt/beegfs/intel/compilers_and_libraries_2018.5.274/linux/mkl/lib/intel64/libmkl_core.a /mnt/beegfs/intel/compilers_and_libraries_2018.5.274/linux/mkl/lib/intel64/libmkl_sequential.a -Wl,--end-group -lpthread -lm -ldl -lstdc++</div><div>mpif90 -no-pie -mavx512f -mavx512er -mavx512cd -mavx512pf -march=native -fno-omit-frame-pointer -g  -O3 -funroll-loops -ffast-math  -fopenmp -I/home/rcohen/CP2K/cp2k/tools/toolchain/build  -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/mpich-3.2.1/include'  -m64 -I/mnt/beegfs/intel/compilers_and_libraries_2018.5.274/linux/mkl/include -I/mnt/beegfs/intel/compilers_and_libraries_2018.5.274/linux/mkl/include/fftw -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/fftw-3.3.7/include' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libint-1.1.6/include' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxc-4.0.3/include' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxsmm-1.10.0/include' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/elpa-2017.05.002/include/elpa_openmp-2017.05.002/modules' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/elpa-2017.05.002/include/elpa_openmp-2017.05.002/elpa' -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/gsl-2.5/include' -I/home/rcohen/CP2K/cp2k/tools/toolchain/install/spglib-1.10.4/include -I/home/rcohen/CP2K/cp2k/tools/toolchain/install/hdf5-1.10.4/include -I'/home/rcohen/CP2K/cp2k/tools/toolchain/install/json_fortran-6.9.0/include' -ffree-form -std=f2003 -fimplicit-none  -Werror=aliasing -Werror=ampersand -Werror=c-binding-type -Werror=intrinsic-shadow -Werror=intrinsics-std -Werror=line-truncation -Werror=tabs -Werror=target-lifetime -Werror=underflow -Werror=unused-but-set-variable -Werror=unused-variable -Werror=unused-dummy-argument -Werror=conversion -Werror=zerotrip -Werror=uninitialized -Wno-maybe-uninitialized -Wuse-without-only  -D__LIBXSMM  -D__parallel  -D__FFTW3  -D__LIBINT -D__LIBINT_MAX_AM=6 -D__LIBDERIV_MAX_AM1=5 -D__LIBXC -D__SCALAPACK -D__ELPA=201705 -D__GSL -D__SPGLIB -D__HDF5 -D__JSON   -D__COMPILE_ARCH="\"local\"" -D__COMPILE_DATE="\"Mon Jan 14 14:15:43 CET 2019\"" -D__COMPILE_HOST="\"tomcat3\"" -D__COMPILE_REVISION="\"git:89b110c40\"" -D__DATA_DIR="\"/home/rcohen/CP2K/cp2k/data\"" -no-pie -Wl,--enable-new-dtags -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/mpich-3.2.1/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/mpich-3.2.1/lib'  -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/fftw-3.3.7/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/fftw-3.3.7/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libint-1.1.6/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/libint-1.1.6/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxc-4.0.3/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxc-4.0.3/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxsmm-1.10.0/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/libxsmm-1.10.0/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/scalapack-2.0.2/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/scalapack-2.0.2/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/elpa-2017.05.002/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/elpa-2017.05.002/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/gsl-2.5/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/gsl-2.5/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/spglib-1.10.4/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/spglib-1.10.4/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/hdf5-1.10.4/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/hdf5-1.10.4/lib' -L'/home/rcohen/CP2K/cp2k/tools/toolchain/install/json_fortran-6.9.0/lib' -Wl,-rpath='/home/rcohen/CP2K/cp2k/tools/toolchain/install/json_fortran-6.9.0/lib'  -L/home/rcohen/CP2K/cp2k/lib/local/psmp -o /home/rcohen/CP2K/cp2k/exe/local/libcp2k_unittest.psmp libcp2k_unittest.o  -lcp2kstart -lcp2kmc -lcp2kswarm -lcp2kmotion -lcp2kthermostat -lcp2kemd -lcp2ktmc -lcp2kmain -lcp2kgrid -ldbcsrarnoldi -ldbcsrx -lcp2kshg_int -lcp2keri_mme -lcp2kminimax -lcp2khfxbase -lcp2ksubsys -lcp2kxc -lcp2kao -lcp2kinput -lcp2kpw -lcp2kfft -lcp2kfm -lcp2kcommon -lcp2kmpiwrap -lcp2kbase -L/home/rcohen/CP2K/cp2k/lib/local/psmp/exts/dbcsr -ldbcsr -ljsonfortran -lhdf5 -lsymspg -lgsl -lgslcblas -lelpa_openmp -lscalapack -lxsmmf -lxsmm -ldl -lpthread -lxcf03 -lxc -Wl,-Bstatic -lderiv -lint -Wl,-Bdynamic -lfftw3 -lfftw3_omp  -lmpi -lmpicxx  -Wl,--start-group /mnt/beegfs/intel/compilers_and_libraries_2018.5.274/linux/mkl/lib/intel64/libmkl_gf_lp64.a /mnt/beegfs/intel/compilers_and_libraries_2018.5.274/linux/mkl/lib/intel64/libmkl_core.a /mnt/beegfs/intel/compilers_and_libraries_2018.5.274/linux/mkl/lib/intel64/libmkl_sequential.a -Wl,--end-group -lpthread -lm -ldl -lstdc++</div><div>/usr/bin/ld: /home/rcohen/CP2K/cp2k/tools/toolchain/install/scalapack-2.0.2/lib/libscalapack.a(dgebs2d_.o)(.text+0xb7): unresolvable R_X86_64_32 relocation against symbol `BI_AuxBuff'</div><div>/usr/bin/ld: final link failed: Nonrepresentable section on output</div><div>collect2: error: ld returned 1 exit status</div><div>/home/rcohen/CP2K/cp2k/obj/local/psmp/all.dep:94: recipe for target '/home/rcohen/CP2K/cp2k/exe/local/cp2k_shell.psmp' failed</div><div>make[3]: *** [/home/rcohen/CP2K/cp2k/exe/local/cp2k_shell.psmp] Error 1</div><div>make[3]: *** Waiting for unfinished jobs....</div><div>/usr/bin/ld: /home/rcohen/CP2K/cp2k/tools/toolchain/install/scalapack-2.0.2/lib/libscalapack.a(dgebs2d_.o)(.text+0xb7): unresolvable R_X86_64_32 relocation against symbol `BI_AuxBuff'</div><div>/usr/bin/ld: final link failed: Nonrepresentable section on output</div><div>collect2: error: ld returned 1 exit status</div><div>/home/rcohen/CP2K/cp2k/obj/local/psmp/all.dep:98: recipe for target '/home/rcohen/CP2K/cp2k/exe/local/libcp2k_unittest.psmp' failed</div><div>make[3]: *** [/home/rcohen/CP2K/cp2k/exe/local/libcp2k_unittest.psmp] Error 1</div><div>/usr/bin/ld: /home/rcohen/CP2K/cp2k/tools/toolchain/install/scalapack-2.0.2/lib/libscalapack.a(dgebs2d_.o)(.text+0xb7): unresolvable R_X86_64_32 relocation against symbol `BI_AuxBuff'</div><div>/usr/bin/ld: final link failed: Nonrepresentable section on output</div><div>collect2: error: ld returned 1 exit status</div><div>/home/rcohen/CP2K/cp2k/obj/local/psmp/all.dep:90: recipe for target '/home/rcohen/CP2K/cp2k/exe/local/cp2k.psmp' failed</div><div>make[3]: *** [/home/rcohen/CP2K/cp2k/exe/local/cp2k.psmp] Error 1</div><div>/home/rcohen/CP2K/cp2k/Makefile:132: recipe for target 'all' failed</div><div>make[2]: *** [all] Error 2</div><div>/home/rcohen/CP2K/cp2k/Makefile:121: recipe for target 'psmp' failed</div><div>make[1]: *** [psmp] Error 2</div><div>Makefile:116: recipe for target 'all' failed</div><div>make: *** [all] Error 2</div></div><div><br></div><div><br></div><div><br></div></div></div>