
This reverts commit 65a333600d5c88a98d674f637d092807cfc12253. This wasn't tested for correctness with something like fodwatch [0], and should not have been (self-)merged so quickly, especially without further review. It also resulted in the breakage of at least one package [1] (and that's the one we know of and was caught). A few packages that were updated in between this commit and this revert were not reverted back to using `rev`, but other than that, this is a 1:1 revert. [0]: https://codeberg.org/raphaelr/fodwatch [1]: https://github.com/NixOS/nixpkgs/pull/396904 / 758551e4587d75882aebc21a04bee960418f8ce9
80 lines
1.3 KiB
Nix
80 lines
1.3 KiB
Nix
{
|
|
stdenv,
|
|
lib,
|
|
fetchFromGitHub,
|
|
gfortran,
|
|
meson,
|
|
ninja,
|
|
pkg-config,
|
|
python3,
|
|
blas,
|
|
lapack,
|
|
mctc-lib,
|
|
mstore,
|
|
multicharge,
|
|
}:
|
|
|
|
assert !blas.isILP64 && !lapack.isILP64;
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "dftd4";
|
|
version = "3.7.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "dftd4";
|
|
repo = "dftd4";
|
|
rev = "v${version}";
|
|
hash = "sha256-dixPCLH5dWkE2/7ghGEXJmX2/g1DN30dB4jX2d7fmio=";
|
|
};
|
|
|
|
patches = [
|
|
# Make sure fortran headers are installed directly in /include
|
|
./fortran-module-dir.patch
|
|
];
|
|
|
|
nativeBuildInputs = [
|
|
gfortran
|
|
meson
|
|
ninja
|
|
pkg-config
|
|
python3
|
|
];
|
|
|
|
buildInputs = [
|
|
blas
|
|
lapack
|
|
mctc-lib
|
|
mstore
|
|
multicharge
|
|
];
|
|
|
|
outputs = [
|
|
"out"
|
|
"dev"
|
|
];
|
|
|
|
doCheck = true;
|
|
|
|
postPatch = ''
|
|
patchShebangs --build \
|
|
config/install-mod.py \
|
|
app/tester.py
|
|
'';
|
|
|
|
preCheck = ''
|
|
export OMP_NUM_THREADS=2
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Generally Applicable Atomic-Charge Dependent London Dispersion Correction";
|
|
mainProgram = "dftd4";
|
|
license = with licenses; [
|
|
lgpl3Plus
|
|
gpl3Plus
|
|
];
|
|
homepage = "https://github.com/grimme-lab/dftd4";
|
|
platforms = platforms.linux;
|
|
maintainers = [ maintainers.sheepforce ];
|
|
};
|
|
}
|