2020-02-03 18:38:03 +01:00
|
|
|
{ stdenv, fetchFromGitHub, cmake, makeWrapper, qtbase , qttools, python
|
|
|
|
, libGLU, libGL , libXt, qtx11extras, qtxmlpatterns , mkDerivation }:
|
2009-03-30 22:06:31 +02:00
|
|
|
|
2019-11-06 11:46:33 +01:00
|
|
|
mkDerivation rec {
|
2019-08-15 14:41:18 +02:00
|
|
|
pname = "paraview";
|
2019-11-06 11:46:33 +01:00
|
|
|
version = "5.6.3";
|
2017-09-10 18:00:38 +02:00
|
|
|
|
|
|
|
# fetching from GitHub instead of taking an "official" source
|
|
|
|
# tarball because of missing submodules there
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Kitware";
|
|
|
|
repo = "ParaView";
|
|
|
|
rev = "v${version}";
|
2019-11-06 11:46:33 +01:00
|
|
|
sha256 = "0zcij59pg47c45gfddnpbin13w16smzhcbivzm1k4pg4366wxq1q";
|
2017-09-10 18:00:38 +02:00
|
|
|
fetchSubmodules = true;
|
2009-03-30 22:06:31 +02:00
|
|
|
};
|
|
|
|
|
2018-03-19 16:43:03 +01:00
|
|
|
cmakeFlags = [
|
|
|
|
"-DPARAVIEW_ENABLE_PYTHON=ON"
|
|
|
|
"-DPARAVIEW_INSTALL_DEVELOPMENT_FILES=ON"
|
|
|
|
"-DPARAVIEW_ENABLE_EMBEDDED_DOCUMENTATION=OFF"
|
2018-07-19 02:05:15 +02:00
|
|
|
"-DOpenGL_GL_PREFERENCE=GLVND"
|
2018-03-19 16:43:03 +01:00
|
|
|
];
|
2017-09-10 18:00:38 +02:00
|
|
|
|
|
|
|
# During build, binaries are called that rely on freshly built
|
|
|
|
# libraries. These reside in build/lib, and are not found by
|
|
|
|
# default.
|
|
|
|
preBuild = ''
|
2020-01-02 01:29:34 +01:00
|
|
|
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH''${LD_LIBRARY_PATH:+:}$PWD/lib:$PWD/VTK/ThirdParty/vtkm/vtk-m/lib
|
2009-12-10 23:19:52 +01:00
|
|
|
'';
|
2015-03-06 12:09:01 +01:00
|
|
|
|
2012-02-16 12:07:07 +01:00
|
|
|
enableParallelBuilding = true;
|
2010-11-10 19:13:04 +01:00
|
|
|
|
2017-12-01 13:49:52 +01:00
|
|
|
nativeBuildInputs = [
|
2017-12-01 13:20:15 +01:00
|
|
|
cmake
|
2018-03-19 16:43:03 +01:00
|
|
|
makeWrapper
|
2017-12-01 13:49:52 +01:00
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
2017-12-01 13:20:15 +01:00
|
|
|
python
|
2018-03-19 16:43:03 +01:00
|
|
|
python.pkgs.numpy
|
2019-11-10 17:44:34 +01:00
|
|
|
libGLU libGL
|
2017-12-01 13:20:15 +01:00
|
|
|
libXt
|
|
|
|
qtbase
|
|
|
|
qtx11extras
|
|
|
|
qttools
|
|
|
|
qtxmlpatterns
|
|
|
|
];
|
2017-09-10 18:00:38 +02:00
|
|
|
|
2018-03-19 16:43:03 +01:00
|
|
|
# Paraview links into the Python library, resolving symbolic links on the way,
|
|
|
|
# so we need to put the correct sitePackages (with numpy) back on the path
|
2020-02-03 18:38:03 +01:00
|
|
|
preFixup = ''
|
|
|
|
wrapQtApp $out/bin/paraview \
|
2020-01-27 13:08:18 +01:00
|
|
|
--prefix PYTHONPATH "${python.pkgs.numpy}/${python.sitePackages}"
|
2020-02-03 18:38:03 +01:00
|
|
|
wrapQtApp $out/bin/pvbatch \
|
2020-01-27 13:08:18 +01:00
|
|
|
--prefix PYTHONPATH "${python.pkgs.numpy}/${python.sitePackages}"
|
2020-02-03 18:38:03 +01:00
|
|
|
wrapQtApp $out/bin/pvpython \
|
2020-01-27 13:08:18 +01:00
|
|
|
--prefix PYTHONPATH "${python.pkgs.numpy}/${python.sitePackages}"
|
2018-03-19 16:43:03 +01:00
|
|
|
'';
|
2009-10-01 22:18:17 +02:00
|
|
|
|
2020-02-03 18:38:03 +01:00
|
|
|
meta = with stdenv.lib; {
|
2017-08-01 22:03:30 +02:00
|
|
|
homepage = http://www.paraview.org/;
|
2009-10-01 22:18:17 +02:00
|
|
|
description = "3D Data analysis and visualization application";
|
2020-02-03 18:38:03 +01:00
|
|
|
license = licenses.free;
|
|
|
|
maintainers = with maintainers; [ guibert ];
|
|
|
|
platforms = platforms.linux;
|
2009-10-01 22:18:17 +02:00
|
|
|
};
|
2009-03-30 22:06:31 +02:00
|
|
|
}
|