Skip to content

Commit

Permalink
vtk: build with system libtiff
Browse files Browse the repository at this point in the history
fixes vtktiff, therefore at least gdcm
  • Loading branch information
globin committed Sep 24, 2019
1 parent feca695 commit 2d6fbcd
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions pkgs/development/libraries/vtk/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ stdenv, fetchurl, cmake, libGLU_combined, libX11, xorgproto, libXt
{ stdenv, fetchurl, cmake, libGLU_combined, libX11, xorgproto, libXt, libtiff
, qtLib ? null
# Darwin support
, Cocoa, CoreServices, DiskArbitration, IOKit, CFNetwork, Security, GLUT, OpenGL
Expand All @@ -20,7 +20,9 @@ stdenv.mkDerivation rec {
sha256 = "0nm7xwwj7rnsxjdv2ssviys8nhci4n9iiiqm2y14s520hl2dsp1d";
};

buildInputs = [ cmake ]
nativeBuildInputs = [ cmake ];

buildInputs = [ libtiff ]
++ optional (qtLib != null) qtLib
++ optionals stdenv.isLinux [ libGLU_combined libX11 xorgproto libXt ]
++ optionals stdenv.isDarwin [ xpc Cocoa CoreServices DiskArbitration IOKit
Expand All @@ -38,7 +40,7 @@ stdenv.mkDerivation rec {
# built and requiring one of the shared objects.
# At least, we use -fPIC for other packages to be able to use this in shared
# objects.
cmakeFlags = [ "-DCMAKE_C_FLAGS=-fPIC" "-DCMAKE_CXX_FLAGS=-fPIC" ]
cmakeFlags = [ "-DCMAKE_C_FLAGS=-fPIC" "-DCMAKE_CXX_FLAGS=-fPIC" "-DVTK_USE_SYSTEM_TIFF=1" ]
++ optional (qtLib != null) [ "-DVTK_USE_QT:BOOL=ON" ]
++ optional stdenv.isDarwin "-DOPENGL_INCLUDE_DIR=${OpenGL}/Library/Frameworks";

Expand Down

0 comments on commit 2d6fbcd

Please sign in to comment.