cp2k: 2025.2 -> 2026.1, update tblite, multicharge, dftd4, jonquil (#532430)

This commit is contained in:
Connor Baker
2026-06-20 00:43:37 +00:00
committed by GitHub
9 changed files with 53 additions and 47 deletions
+5 -8
View File
@@ -26,7 +26,7 @@
pkg-config,
plumed,
zlib,
hdf5-fortran,
hdf5-fortran-mpi,
sirius,
libvdwxc,
spla,
@@ -131,13 +131,13 @@ let
in
stdenv.mkDerivation (finalAttrs: {
pname = "cp2k";
version = "2025.2";
version = "2026.1-unstable-2026-06-16";
src = fetchFromGitHub {
owner = "cp2k";
repo = "cp2k";
rev = "v${finalAttrs.version}";
hash = "sha256-vfl5rCoFeGtYuZ7LcsVsESjKxFbN5IYDvBSzOqsd64w=";
rev = "c28f603b5956aa638ef130b21b091da4e3a17639";
hash = "sha256-LIghR2gCYbJDux4bFfeKCi+a+VDVbjcZfcVpYwjPkEg=";
fetchSubmodules = true;
};
@@ -175,7 +175,7 @@ stdenv.mkDerivation (finalAttrs: {
dbcsr
plumed
zlib
hdf5-fortran
hdf5-fortran-mpi
spla
spfft
libvdwxc
@@ -207,9 +207,6 @@ stdenv.mkDerivation (finalAttrs: {
postPatch = ''
patchShebangs tools exts/dbcsr/tools/build_utils exts/dbcsr/.cp2k
substituteInPlace exts/build_dbcsr/Makefile \
--replace '/usr/bin/env python3' '${python3}/bin/python' \
--replace 'SHELL = /bin/sh' 'SHELL = bash'
'';
cmakeFlags = [
@@ -1,5 +1,5 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index f222aab..262b505 100644
index 3db5442..64fa14a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -89,7 +89,6 @@ target_include_directories(
@@ -20,29 +20,38 @@ index f222aab..262b505 100644
if(WITH_API)
enable_language("C")
diff --git a/config/template.cmake b/config/template.cmake
index 8b5141d..8f94d66 100644
index 8b5141d..76654d1 100644
--- a/config/template.cmake
+++ b/config/template.cmake
@@ -6,7 +6,6 @@ set("@PROJECT_NAME@_WITH_OpenMP" @WITH_OpenMP@)
@@ -5,8 +5,7 @@ set("@PROJECT_NAME@_WITH_API_V2" @WITH_API_V2@)
set("@PROJECT_NAME@_WITH_OpenMP" @WITH_OpenMP@)
set(
"@PROJECT_NAME@_INCLUDE_DIRS"
"@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_INCLUDEDIR@"
- "@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_INCLUDEDIR@"
- "@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_INCLUDEDIR@/@module-dir@"
+ "@CMAKE_INSTALL_FULL_INCLUDEDIR@"
)
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}")
diff --git a/config/template.pc b/config/template.pc
index 3d6efbb..fea69e4 100644
index 3d6efbb..55b899f 100644
--- a/config/template.pc
+++ b/config/template.pc
@@ -6,4 +6,4 @@ Name: @PROJECT_NAME@
@@ -1,9 +1,9 @@
prefix=@CMAKE_INSTALL_PREFIX@
-libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@
-includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@
+libdir=@CMAKE_INSTALL_FULL_LIBDIR@
+includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@
Name: @PROJECT_NAME@
Description: @PROJECT_DESCRIPTION@
Version: @PROJECT_VERSION@
Libs: -L${libdir} -l@PROJECT_NAME@
-Cflags: -I${includedir} -I${includedir}/@module-dir@
+Cflags: -I${includedir} -I${includedir}/
diff --git a/meson.build b/meson.build
index c9e9c58..ac8f0bd 100644
index 7de7d61..81b8a7d 100644
--- a/meson.build
+++ b/meson.build
@@ -83,7 +83,7 @@ if install
-13
View File
@@ -1,13 +0,0 @@
diff --git a/config/template.pc b/config/template.pc
index 3d6efbb..e338a42 100644
--- a/config/template.pc
+++ b/config/template.pc
@@ -1,6 +1,6 @@
prefix=@CMAKE_INSTALL_PREFIX@
-libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@
-includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@
+libdir=@CMAKE_INSTALL_FULL_LIBDIR@
+includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@
Name: @PROJECT_NAME@
Description: @PROJECT_DESCRIPTION@
+4 -7
View File
@@ -26,21 +26,18 @@ assert (
stdenv.mkDerivation (finalAttrs: {
pname = "dftd4";
version = "3.7.0";
version = "4.2.0";
src = fetchFromGitHub {
owner = "dftd4";
repo = "dftd4";
rev = "v${finalAttrs.version}";
hash = "sha256-dixPCLH5dWkE2/7ghGEXJmX2/g1DN30dB4jX2d7fmio=";
hash = "sha256-uKjNOIza3/I0oREp88oFESoNqEdumo1AztIjcrVb1O8=";
};
patches = [
# Make sure fortran headers are installed directly in /include
./fortran-module-dir.patch
# Fix wrong generation of package config include paths
./cmake.patch
# Fix pkg-config, meson and cmake paths for include and lib dirs
./build-paths.patch
];
nativeBuildInputs = [
+2 -2
View File
@@ -21,13 +21,13 @@ assert (
stdenv.mkDerivation (finalAttrs: {
pname = "jonquil";
version = "0.3.0";
version = "0.3.1";
src = fetchFromGitHub {
owner = "toml-f";
repo = "jonquil";
rev = "v${finalAttrs.version}";
hash = "sha256-2JCTHA0nyA7xE0IA+LNrEAulHU2eIbNRvFGQ7YSQMRE=";
hash = "sha256-xKL3EWZaHdMAuUK7pL2vjfRk8Fq2uNL65TrGUyFQ5cc=";
};
patches = [
+3 -1
View File
@@ -50,7 +50,9 @@ stdenv.mkDerivation (finalAttrs: {
]
++ lib.optional (buildType == "cmake") cmake;
buildInputs = [
propagatedBuildInputs = [
# jonquil (and the toml-f it propagates) appears in mctc-lib.pc's Requires.private, so it must
# be propagated for pkg-config consumers (e.g. dftd4) to resolve mctc-lib
jonquil
];
+7 -2
View File
@@ -25,13 +25,13 @@ assert (
stdenv.mkDerivation (finalAttrs: {
pname = "multicharge";
version = "0.3.1";
version = "0.5.0";
src = fetchFromGitHub {
owner = "grimme-lab";
repo = "multicharge";
rev = "v${finalAttrs.version}";
hash = "sha256-8qwM3dpvFoL2WrMWNf14zYtRap0ijdfZ95XaTlkHhqQ=";
hash = "sha256-hswqC+fvC6tuxDpuUgowyqm72ubVikzpR4EzXtTM5cs=";
};
patches = [
@@ -69,6 +69,11 @@ stdenv.mkDerivation (finalAttrs: {
postPatch = ''
patchShebangs --build config/install-mod.py
# custom blas and lapack need to be explicitly found for transitive dependencies
# otherwise CMAKE builds can not proceed.
echo 'set(custom-blas_FOUND TRUE)' >> config/cmake/Findcustom-blas.cmake
echo 'set(custom-lapack_FOUND TRUE)' >> config/cmake/Findcustom-lapack.cmake
'';
preCheck = ''
@@ -1,6 +1,6 @@
{
stdenv,
lib,
stdenv,
fetchFromGitHub,
gfortran,
buildType ? "meson",
@@ -29,13 +29,13 @@ assert (
stdenv.mkDerivation rec {
pname = "tblite";
version = "0.5.0";
version = "0.6.0";
src = fetchFromGitHub {
owner = "tblite";
repo = "tblite";
rev = "v${version}";
hash = "sha256-hePy/slEeM2o1gtrAbq/nkEUILa6oQjkD2ddDstQ2Zc=";
hash = "sha256-z0g+bf6APqNLB9mDE49FelitQ9ptZXdFQuYeXIT0NIw=";
};
patches = [
@@ -45,10 +45,18 @@ stdenv.mkDerivation rec {
./pkgconfig.patch
];
# Python scripts in test subdirectories to run the tests
postPatch = ''
patchShebangs ./
'';
postPatch =
# Python scripts in test subdirectories to run the tests
''
patchShebangs ./
''
# libquadmath is only shipped by GCC on architectures that lack native
# quad-precision support (e.g. x86_64); on aarch64 it does not exist.
+ lib.optionalString (stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch64) ''
substituteInPlace config/meson.build \
--replace-fail "lib_deps += cc.find_library('quadmath')" ""
'';
nativeBuildInputs = [
gfortran
@@ -23,6 +23,7 @@ buildPythonPackage {
pname
version
src
postPatch
meta
;