From 1a6e93f0b2f3efa816d494ed5054bf38f3f75a51 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Josef=20Kemetm=C3=BCller?= Date: Thu, 31 Jan 2019 22:41:34 +0100 Subject: [PATCH] pythonPackages.mayavi: init at 4.7.0 --- .../python-modules/mayavi/default.nix | 37 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 39 insertions(+) create mode 100644 pkgs/development/python-modules/mayavi/default.nix diff --git a/pkgs/development/python-modules/mayavi/default.nix b/pkgs/development/python-modules/mayavi/default.nix new file mode 100644 index 000000000000..d7a821915f20 --- /dev/null +++ b/pkgs/development/python-modules/mayavi/default.nix @@ -0,0 +1,37 @@ +{ stdenv, fetchPypi, buildPythonPackage +, wxPython, pygments, numpy, vtk, traitsui, envisage, apptools +, nose, mock +, isPy3k +}: + +buildPythonPackage rec { + pname = "mayavi"; + version = "4.7.0"; + + src = fetchPypi { + inherit pname version; + extension = "tar.bz2"; + sha256 = "02rg4j1vkny2piqn3f728kg34m54kgx396g6h5y7ykz2lk3f3h44"; + }; + + # Discovery of 'vtk' in setuptools is not working properly, due to a missing + # .egg-info in the vtk package. It does however import and run just fine. + postPatch = '' + substituteInPlace mayavi/__init__.py --replace "'vtk'" "" + ''; + + propagatedBuildInputs = [ wxPython pygments numpy vtk traitsui envisage apptools ]; + + checkInputs = [ nose mock ]; + + disabled = isPy3k; # TODO: This would need pyqt5 instead of wxPython + + doCheck = false; # Needs X server + + meta = with stdenv.lib; { + description = "3D visualization of scientific data in Python"; + homepage = https://github.com/enthought/mayavi; + maintainers = with stdenv.lib.maintainers; [ knedlsepp ]; + license = licenses.bsdOriginal; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 3ad2c853c761..118604b7d859 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -4143,6 +4143,8 @@ in { maya = callPackage ../development/python-modules/maya { }; + mayavi = callPackage ../development/python-modules/mayavi { }; + mccabe = callPackage ../development/python-modules/mccabe { }; mechanize = callPackage ../development/python-modules/mechanize { };