2018-09-11 21:41:17 +01:00
|
|
|
{ stdenv, fetchurl
|
2020-03-31 15:47:18 +01:00
|
|
|
, gfortran, fftw, blas, lapack
|
2018-09-11 21:41:17 +01:00
|
|
|
, mpi ? null
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2020-02-24 19:40:14 +00:00
|
|
|
version = "6.5";
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "quantum-espresso";
|
2018-09-11 21:41:17 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "https://gitlab.com/QEF/q-e/-/archive/qe-${version}/q-e-qe-${version}.tar.gz";
|
2020-02-24 19:40:14 +00:00
|
|
|
sha256 = "00nnsq1vq579xsmkvwrgs6bdqdcbdlsmcp4yfynnvs40ca52m2r5";
|
2018-09-11 21:41:17 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
passthru = {
|
|
|
|
inherit mpi;
|
|
|
|
};
|
|
|
|
|
|
|
|
preConfigure = ''
|
|
|
|
patchShebangs configure
|
|
|
|
'';
|
|
|
|
|
2020-03-31 15:47:18 +01:00
|
|
|
buildInputs = [ fftw blas lapack gfortran ]
|
2018-09-11 21:41:17 +01:00
|
|
|
++ (stdenv.lib.optionals (mpi != null) [ mpi ]);
|
|
|
|
|
|
|
|
configureFlags = if (mpi != null) then [ "LD=${mpi}/bin/mpif90" ] else [ "LD=${gfortran}/bin/gfortran" ];
|
|
|
|
|
|
|
|
makeFlags = [ "all" ];
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Electronic-structure calculations and materials modeling at the nanoscale";
|
|
|
|
longDescription = ''
|
|
|
|
Quantum ESPRESSO is an integrated suite of Open-Source computer codes for
|
|
|
|
electronic-structure calculations and materials modeling at the
|
|
|
|
nanoscale. It is based on density-functional theory, plane waves, and
|
|
|
|
pseudopotentials.
|
|
|
|
'';
|
2020-02-24 19:40:14 +00:00
|
|
|
homepage = "https://www.quantum-espresso.org/";
|
2018-09-11 21:41:17 +01:00
|
|
|
license = licenses.gpl2;
|
|
|
|
platforms = [ "x86_64-linux" ];
|
|
|
|
maintainers = [ maintainers.costrouc ];
|
|
|
|
};
|
|
|
|
}
|