mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-22 14:45:27 +00:00
pythonPackages.pygmo: init at 2.8
- python 2.7, 3+ - skipping tests becuase none are easy to run (require some parallel workers) - fetchFromgitHub so that running tests in future is possible
This commit is contained in:
parent
def307e476
commit
ff27546351
48
pkgs/development/python-modules/pygmo/default.nix
Normal file
48
pkgs/development/python-modules/pygmo/default.nix
Normal file
|
@ -0,0 +1,48 @@
|
|||
{ lib
|
||||
, fetchFromGitHub
|
||||
, buildPythonPackage
|
||||
, cmake
|
||||
, eigen
|
||||
, nlopt
|
||||
, ipopt
|
||||
, boost
|
||||
, pagmo2
|
||||
, numpy
|
||||
, cloudpickle
|
||||
, ipyparallel
|
||||
, numba
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "pygmo";
|
||||
version = "2.8";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "esa";
|
||||
repo = "pagmo2";
|
||||
rev = "v${version}";
|
||||
sha256 = "1xwxamcn3fkwr62jn6bkanrwy0cvsksf75hfwx4fvl56awnbz41z";
|
||||
};
|
||||
|
||||
buildInputs = [ cmake eigen nlopt ipopt boost pagmo2 ];
|
||||
propagatedBuildInputs = [ numpy cloudpickle ipyparallel numba ];
|
||||
|
||||
preBuild = ''
|
||||
cp -v -r $src/* .
|
||||
cmake -DCMAKE_INSTALL_PREFIX=$out -DPAGMO_BUILD_TESTS=no -DCMAKE_SYSTEM_NAME=Linux -DPagmo_DIR=${pagmo2} -DPAGMO_BUILD_PYGMO=yes -DPAGMO_BUILD_PAGMO=no -DPAGMO_WITH_EIGEN3=yes -DPAGMO_WITH_NLOPT=yes -DNLOPT_LIBRARY=${nlopt}/lib/libnlopt_cxx.so -DPAGMO_WITH_IPOPT=yes -DIPOPT=${ipopt}
|
||||
|
||||
make install
|
||||
mv $out/lib/python*/site-packages/pygmo wheel
|
||||
cd wheel
|
||||
'';
|
||||
|
||||
# dont do tests
|
||||
doCheck = false;
|
||||
|
||||
meta = {
|
||||
description = "Parallel optimisation for Python";
|
||||
homepage = https://esa.github.io/pagmo2/;
|
||||
license = lib.licenses.gpl3Plus;
|
||||
maintainers = with lib.maintainers; [ costrouc ];
|
||||
};
|
||||
}
|
|
@ -408,6 +408,8 @@ in {
|
|||
|
||||
pygame_sdl2 = callPackage ../development/python-modules/pygame_sdl2 { };
|
||||
|
||||
pygmo = callPackage ../development/python-modules/pygmo { };
|
||||
|
||||
pygobject2 = callPackage ../development/python-modules/pygobject { };
|
||||
|
||||
pygobject3 = callPackage ../development/python-modules/pygobject/3.nix { };
|
||||
|
|
Loading…
Reference in a new issue