about summary refs log tree commit diff
path: root/pkgs/development/python-modules/pygmo/default.nix
blob: c829ff91f6969d5351afce3d97f6d599955c6607 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
{ lib
, stdenv
, toPythonModule
, fetchFromGitHub
, cmake
, boost
, eigen
, ipopt
, nlopt
, pagmo2
, python
, cloudpickle
, ipyparallel
, numba
, numpy
, pybind11
}:

toPythonModule (stdenv.mkDerivation rec {
  pname = "pygmo";
  version = "2.19.6";

  src = fetchFromGitHub {
    owner = "esa";
    repo = "pygmo2";
    rev = "refs/tags/v${version}";
    hash = "sha256-umXK8LGJJ6Xj6UbJ5k/DM/nYayjl+jBXtjar5/dWqFM=";
  };

  cmakeFlags = [
    "-DPYGMO_INSTALL_PATH=${placeholder "out"}/${python.sitePackages}"
  ];

  nativeBuildInputs = [
    cmake
  ];

  propagatedBuildInputs = [
    cloudpickle
    ipyparallel
    numba
    numpy
    python
  ];

  buildInputs = [
    boost
    eigen
    ipopt
    nlopt
    pagmo2
    pybind11
  ];

  doCheck = true;

  meta = with lib; {
    description = "Parallel optimisation for Python";
    homepage = "https://github.com/esa/pygmo2";
    license = licenses.gpl3Plus;
    maintainers = [ ];
  };
})