diff --git a/tools/toolchain/scripts/install_mpich.sh b/tools/toolchain/scripts/install_mpich.sh index c78ed25f63..7b411106c5 100755 --- a/tools/toolchain/scripts/install_mpich.sh +++ b/tools/toolchain/scripts/install_mpich.sh @@ -41,7 +41,11 @@ case "$with_mpich" in cd mpich-${mpich_ver} unset F90 unset F90FLAGS - ./configure --prefix="${pkg_install_dir}" --libdir="${pkg_install_dir}/lib" MPICC="" --without-x --enable-gl=no > configure.log 2>&1 + + # workaround for compilation with GCC-10, until properly fixed: + # https://github.com/pmodels/mpich/issues/4300 + ( "${FC}" --version | grep -Eq 'GNU.+\s10\.') && compat_flag="-fallow-argument-mismatch" || compat_flag="" + ./configure --prefix="${pkg_install_dir}" --libdir="${pkg_install_dir}/lib" MPICC="" FFLAGS="${FCFLAGS} ${compat_flag}" FCFLAGS="${FCFLAGS} ${compat_flag}" --without-x --enable-gl=no > configure.log 2>&1 make -j $NPROCS > make.log 2>&1 make install > install.log 2>&1 cd .. diff --git a/tools/toolchain/scripts/install_plumed.sh b/tools/toolchain/scripts/install_plumed.sh index ca18dda140..8f7ac28139 100755 --- a/tools/toolchain/scripts/install_plumed.sh +++ b/tools/toolchain/scripts/install_plumed.sh @@ -40,8 +40,11 @@ case "$with_plumed" in echo "Installing from scratch into ${pkg_install_dir}" cd plumed-${plumed_ver} - ./configure CXX="${MPICXX}" --prefix=${pkg_install_dir} --libdir="${pkg_install_dir}/lib" > configure.log 2>&1 - make -j $NPROCS > make.log 2>&1 + # disable generating debugging infos for now to work around an issue in gcc-10.2: + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96354 + # note: some MPI wrappers carry a -g forward, thus stripping is not enough + ./configure CXX="${MPICXX}" CXXFLAGS="${CXXFLAGS//-g/-g0}" --prefix=${pkg_install_dir} --libdir="${pkg_install_dir}/lib" > configure.log 2>&1 + make VERBOSE=1 -j $NPROCS > make.log 2>&1 make install > install.log 2>&1 write_checksums "${install_lock_file}" "${SCRIPT_DIR}/$(basename ${SCRIPT_NAME})" fi diff --git a/tools/toolchain/scripts/install_quip.sh b/tools/toolchain/scripts/install_quip.sh index c936e39fcf..e80d8eaef6 100755 --- a/tools/toolchain/scripts/install_quip.sh +++ b/tools/toolchain/scripts/install_quip.sh @@ -80,9 +80,14 @@ case "$with_quip" in -e "s|\(QUIPPY_FCOMPILER *=\).*|\1 ${FC}|g" \ -e "s|\(QUIPPY_CPP *=\).*|\1 ${FC} -E -x f95-cpp-input|g" \ arch/Makefile.linux_${quip_arch}_gfortran + + # workaround for compilation with GCC-10, until properly fixed: + # https://github.com/libAtoms/QUIP/issues/209 + ( "${FC}" --version | grep -Eq 'GNU.+\s10\.') && compat_flag="-fallow-argument-mismatch" || compat_flag="" + # enable debug symbols - echo "F95FLAGS += -g" >> arch/Makefile.linux_${quip_arch}_gfortran - echo "F77FLAGS += -g" >> arch/Makefile.linux_${quip_arch}_gfortran + echo "F95FLAGS += -g ${compat_flag}" >> arch/Makefile.linux_${quip_arch}_gfortran + echo "F77FLAGS += -g ${compat_flag}" >> arch/Makefile.linux_${quip_arch}_gfortran echo "CFLAGS += -g" >> arch/Makefile.linux_${quip_arch}_gfortran echo "CPLUSPLUSFLAGS += -g" >> arch/Makefile.linux_${quip_arch}_gfortran export QUIP_ARCH=linux_${quip_arch}_gfortran