libraries/VTK: provide switches to enable features.

Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
This commit is contained in:
Youjie Zhou 2014-11-18 01:48:27 +07:00 committed by Willy Sudiarto Raharjo
parent 88eaef7c75
commit 5ebda94788
2 changed files with 45 additions and 15 deletions

View file

@ -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)

View file

@ -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 ..