summaryrefslogtreecommitdiff
path: root/libraries/VTK
diff options
context:
space:
mode:
Diffstat (limited to 'libraries/VTK')
-rw-r--r--libraries/VTK/README33
-rw-r--r--libraries/VTK/VTK.SlackBuild27
2 files changed, 45 insertions, 15 deletions
diff --git a/libraries/VTK/README b/libraries/VTK/README
index e85f751d40..567d99816d 100644
--- a/libraries/VTK/README
+++ b/libraries/VTK/README
@@ -1,13 +1,22 @@
-The Visualization Toolkit (VTK) is an open source, freely available
-software system for 3D computer graphics, modeling, image processing,
-volume rendering, scientific visualization and information
-visualization. VTK also includes ancillary support for 3D interaction
-widgets, two and three-dimensional annotation, and parallel
-computing. At its core VTK is implemented as a C++ toolkit, requiring
-users to build applications by combining various objects into an
-application. The system also supports automated wrapping of the C++
-core into Python, Java and Tcl, so that VTK applications may also be
-written using these interpreted programming languages.
+The Visualization Toolkit (VTK) is an open source, freely available software
+system for 3D computer graphics, modeling, image processing, volume rendering,
+scientific visualization and information visualization. VTK also includes
+ancillary support for 3D interaction widgets, two and three-dimensional
+annotation, and parallel computing. At its core VTK is implemented as a C++
+toolkit, requiring users to build applications by combining various objects into
+an application. The system also supports automated wrapping of the C++ core into
+Python, Java and Tcl, so that VTK applications may also be written using these
+interpreted programming languages.
-VTK provides several language bindings. You may need to modify related
-cmake options. Only Qt binding is enabled by default.
+You can enable a lot of optional features by passing variables to the script
+(VAR=yes/no ./VTK.SlackBuild):
+
+IMAGING=yes|no (default: no)
+MPI=yes|no (default: no), requires openmpi
+QT=yes|no (default: yes)
+TK=yes|no (default: no)
+VIEWS=yes|no (default: no)
+WEB=yes|no (default: no)
+PYTHON=yes|no (default: yes)
+JAVA=yes|no (default: no)
+TCL=yes|no (default: no) \ No newline at end of file
diff --git a/libraries/VTK/VTK.SlackBuild b/libraries/VTK/VTK.SlackBuild
index 6c2b8c7d99..4391f4add5 100644
--- a/libraries/VTK/VTK.SlackBuild
+++ b/libraries/VTK/VTK.SlackBuild
@@ -24,6 +24,7 @@
#
# 2014-02-14 Merge lib64 patch from Christoph Willing <c.willing@uq.edu.au>
# 2014-02-16 Update to 6.1.0
+# 2014-11-16 Support VTK features
PRGNAM=VTK
VERSION=${VERSION:-6.1.0}
@@ -57,6 +58,17 @@ else
LIBDIRSUFFIX=""
fi
+# configure VTK features
+group_imaging="" ; [ "${IMAGING:-no}" != "no" ] && group_imaging="-DVTK_Group_Imaging=true"
+group_mpi="" ; [ "${MPI:-no}" != "no" ] && group_mpi="-DVTK_Group_MPI=true"
+group_qt="" ; [ "${QT:-yes}" != "no" ] && group_qt="-DVTK_Group_Qt=true"
+group_tk="" ; [ "${TK:-no}" != "no" ] && group_tk="-DVTK_Group_Tk=true"
+group_views="" ; [ "${VIEWS:-no}" != "no" ] && group_views="-DVTK_Group_Views=true"
+group_web="" ; [ "${WEB:-no}" != "no" ] && group_web="-DVTK_Group_Web=true"
+wrap_python="" ; [ "${PYTHON:-yes}" != "no" ] && wrap_python="-DVTK_WRAP_PYTHON=true"
+wrap_java="" ; [ "${JAVA:-no}" != "no" ] && wrap_java="-DVTK_WRAP_JAVA=true"
+wrap_tcl="" ; [ "${TCL:-no}" != "no" ] && wrap_tcl="-DVTK_WRAP_TCL=true"
+
set -e
rm -rf $PKG
@@ -83,10 +95,19 @@ cd build
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_BUILD_TYPE=Release \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
- -DVTK_Group_Qt=ON \
- -DBUILD_SHARED_LIBS=ON ..
+ -DBUILD_SHARED_LIBS=ON \
+ $group_imaging \
+ $group_mpi \
+ $group_qt \
+ $group_tk \
+ $group_views \
+ $group_web \
+ $wrap_python \
+ $wrap_java \
+ $wrap_tcl \
+ ..
- make -j4
+ make
make install DESTDIR=$PKG
cd ..