1{ buildPythonPackage, lib, fetchFromGitHub, libcint, libxc, xcfun, blas
2, numpy, scipy, h5py
3}:
4
5buildPythonPackage rec {
6 pname = "pyscf";
7 version = "1.7.6.post1";
8
9 src = fetchFromGitHub {
10 owner = "pyscf";
11 repo = pname;
12 rev = "f6c9c6654dd9609c5e467a1edd5c2c076f793acc";
13 sha256 = "0xbwkjxxysfpqz72qn6n4a0zr2h6sprbcal8j7kzymh7swjy117w";
14 };
15
16 # Backport from the 2.0.0 alpha releases of PySCF.
17 # H5Py > 3.3 deprecates the file modes, that PySCF sets.
18 patches = [ ./h5py.patch ];
19
20 buildInputs = [
21 libcint
22 libxc
23 xcfun
24 blas
25 ];
26
27 propagatedBuildInputs = [
28 numpy
29 scipy
30 h5py
31 ];
32
33 PYSCF_INC_DIR="${libcint}:${libxc}:${xcfun}";
34
35 doCheck = false;
36 pythonImportsCheck = [ "pyscf" ];
37
38 meta = with lib; {
39 description = "Python-based simulations of chemistry framework";
40 homepage = "https://github.com/pyscf/pyscf";
41 license = licenses.asl20;
42 platforms = platforms.linux;
43 maintainers = [ maintainers.sheepforce ];
44 };
45}