aboutsummaryrefslogtreecommitdiff
path: root/libraries/VTK
diff options
context:
space:
mode:
authorChristoph Willing <chris.willing@linux.com>2019-02-11 18:03:24 +1000
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2019-02-17 21:56:39 +0700
commit7a76ba7d57b70ebd3ac37cfdfe4f5d48a9f9701b (patch)
tree3f9b550590378e18d0256f25b9b16583bd2c3d5b /libraries/VTK
parent34b6754b7bf0a757de6a2ff085c294358545d5c2 (diff)
libraries/VTK: Updated foe version 8.2.0
Signed-off-by: Christoph Willing <chris.willing@linux.com>
Diffstat (limited to 'libraries/VTK')
-rw-r--r--libraries/VTK/README12
-rw-r--r--libraries/VTK/VTK.SlackBuild44
-rw-r--r--libraries/VTK/VTK.info6
-rw-r--r--libraries/VTK/patch-handle-64bit.diff56
4 files changed, 37 insertions, 81 deletions
diff --git a/libraries/VTK/README b/libraries/VTK/README
index df8c6317fc00f..d24b76957c59f 100644
--- a/libraries/VTK/README
+++ b/libraries/VTK/README
@@ -10,15 +10,23 @@ interpreted programming languages.
Since version 8.1.0, VTK requires the qt5 package.
+Some optional additional packages, if detected during configuration, are used
+in preference to versions provided in the source code. These packages, available
+from SlackBuilds.org, are:
+ jsoncpp proj
+
You can enable a number of optional features by passing variables to the script
-(VAR=yes/no ./VTK.SlackBuild):
+(VAR=yes|no ./VTK.SlackBuild):
IMAGING=yes|no (default: no)
MPI=yes|no (default: no), requires openmpi
-TCL=yes|no (default: yes)
TK=yes|no (default: yes)
VIEWS=yes|no (default: no)
WEB=yes|no (default: no), requires python-twisted
JAVA=yes|no (default: no), requires jdk
PYTHON=yes|no (default: yes)
QT=yes|no (default: yes)
+
+VTK is an optional dependency for the opencv SlackBuild. However since VTK-8.2.0,
+it is not suitable as an optional dependency for opencv-legacy. The last suitable
+version of VTK for building opencv-legacy is VTK-8.1.2.
diff --git a/libraries/VTK/VTK.SlackBuild b/libraries/VTK/VTK.SlackBuild
index 25b9811c0a448..7a216d4c0f3ce 100644
--- a/libraries/VTK/VTK.SlackBuild
+++ b/libraries/VTK/VTK.SlackBuild
@@ -4,7 +4,7 @@
# Copyright 2013,2014 Youjie Zhou <jmpopush@gmail.com>
# All rights reserved.
-# Copyright 2016-2018 Christoph Willing, Brisbane Australia
+# Copyright 2016-2019 Christoph Willing, Brisbane Australia
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -26,8 +26,8 @@
#
PRGNAM=VTK
-VERSION=${VERSION:-8.1.2}
-SHORT_VERSION=${SHORT_VERSION:-8.1}
+VERSION=${VERSION:-8.2.0}
+SHORT_VERSION=${SHORT_VERSION:-8.2}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -68,7 +68,18 @@ group_views="" ; [ "${VIEWS:-no}" != "no" ] && group_views="-DVTK_Group_Vie
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:-yes}" != "no" ] && wrap_tcl="-DVTK_WRAP_TCL=true"
+
+if pkg-config --exists jsoncpp ; then jsoncpp="-DVTK_USE_SYSTEM_JSONCPP:BOOL=ON" ; else jsoncpp="" ; fi
+if pkg-config --exists proj ; then proj="-DVTK_USE_SYSTEM_LIBPROJ:BOOL=ON" ; else proj="" ; fi
+
+# TODO: netcdf, hdf5, gl2ps
+#if test -e /usr/include/hdf5.h ; then hdf5="-DVTK_USE_SYSTEM_HDF5:BOOL=ON" ; else hdf5="" ; fi
+hdf5=""
+netcdf=""
+
+# gl2ps 1.4.0 is needed (+ VTK-specific changes)
+#if test -e /usr/include/gl2ps.h ; then gl2ps="-DVTK_USE_SYSTEM_GL2PS:BOOL=ON" ; else gl2ps="" ; fi
+gl2ps=""
set -e
@@ -86,24 +97,13 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
-# patch CMakefile first for lib64 issue
-patch -p0 <$CWD/patch-handle-64bit.diff
-
-# -DVTK_CUSTOM_LIBRARY_SUFFIX and -DVTK_INSTALL_INCLUDE_DIR
-# See https://bugs.archlinux.org/task/43378?project=5&cat[0]=33&string=vtk
-# -DVTK_USE_SYSTEM_*
-# Use external deps for everything in Slackware, but not SBo (VTK's cmake
-# tests are broken and unable to use external jsoncpp, proj, netcdf, hdf5 and
-# gl2ps). That just leaves python-twisted -- use SBo for that, because the
-# internal twisted overwrites SBo's if it's already installed :O
-
mkdir -p build
cd build
cmake \
-DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
-DCMAKE_INSTALL_PREFIX=/usr \
- -DLIB_SUFFIX=$LIBDIRSUFFIX \
+ -DCMAKE_INSTALL_LIBDIR=lib${LIBDIRSUFFIX} \
-DBUILD_SHARED_LIBS=ON \
-DVTK_CUSTOM_LIBRARY_SUFFIX="" \
-DVTK_INSTALL_INCLUDE_DIR:PATH=include/VTK \
@@ -115,17 +115,21 @@ cd build
$group_web \
$wrap_python \
$wrap_java \
- $wrap_tcl \
-DVTK_USE_SYSTEM_EXPAT:BOOL=ON \
-DVTK_USE_SYSTEM_FREETYPE:BOOL=ON \
+ -DVTK_USE_SYSTEM_GLEW:BOOL=ON \
-DVTK_USE_SYSTEM_JPEG:BOOL=ON \
-DVTK_USE_SYSTEM_LIBXML2:BOOL=ON \
- -DVTK_USE_SYSTEM_OGGTHEORA:BOOL=ON \
+ -DVTK_USE_SYSTEM_OGG:BOOL=ON \
+ -DVTK_USE_SYSTEM_THEORA:BOOL=ON \
-DVTK_USE_SYSTEM_PNG:BOOL=ON \
-DVTK_USE_SYSTEM_TIFF:BOOL=ON \
-DVTK_USE_SYSTEM_ZLIB:BOOL=ON \
- -DVTK_USE_SYSTEM_ZOPE:BOOL=ON \
- -DVTK_USE_SYSTEM_TWISTED:BOOL=ON \
+ $jsoncpp \
+ $proj \
+ $gl2ps \
+ $hdf5 \
+ $netcdf \
-DCMAKE_BUILD_TYPE=Release ..
make
diff --git a/libraries/VTK/VTK.info b/libraries/VTK/VTK.info
index c0c0f480238ab..49e1afcade231 100644
--- a/libraries/VTK/VTK.info
+++ b/libraries/VTK/VTK.info
@@ -1,8 +1,8 @@
PRGNAM="VTK"
-VERSION="8.1.2"
+VERSION="8.2.0"
HOMEPAGE="https://www.vtk.org"
-DOWNLOAD="https://www.vtk.org/files/release/8.1/VTK-8.1.2.tar.gz"
-MD5SUM="fe77ae0414ab8b550f94a0f299502a2e"
+DOWNLOAD="https://www.vtk.org/files/release/8.2/VTK-8.2.0.tar.gz"
+MD5SUM="8af3307da0fc2ef8cafe4a312b821111"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="qt5"
diff --git a/libraries/VTK/patch-handle-64bit.diff b/libraries/VTK/patch-handle-64bit.diff
deleted file mode 100644
index 128d2a9dd38cf..0000000000000
--- a/libraries/VTK/patch-handle-64bit.diff
+++ /dev/null
@@ -1,56 +0,0 @@
---- CMakeLists.txt.orig 2013-12-31 07:20:28.000000000 +1000
-+++ CMakeLists.txt 2014-01-15 10:20:36.928326331 +1000
-@@ -55,13 +55,13 @@
- endif()
- if(NOT CMAKE_LIBRARY_OUTPUT_DIRECTORY)
- if(UNIX)
-- set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${VTK_BINARY_DIR}/lib")
-+ set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${VTK_BINARY_DIR}/lib${LIB_SUFFIX}")
- else()
- set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${VTK_BINARY_DIR}/bin")
- endif()
- endif()
- if(NOT CMAKE_ARCHIVE_OUTPUT_DIRECTORY)
-- set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${VTK_BINARY_DIR}/lib")
-+ set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${VTK_BINARY_DIR}/lib${LIB_SUFFIX}")
- endif()
- mark_as_advanced(CMAKE_RUNTIME_OUTPUT_DIRECTORY
- CMAKE_LIBRARY_OUTPUT_DIRECTORY
-@@ -78,14 +78,17 @@
- "${VTK_MAJOR_VERSION}.${VTK_MINOR_VERSION}.${VTK_BUILD_VERSION}")
-
- # VTK installation structure
-+IF(NOT LIB_SUFFIX)
-+ SET(LIB_SUFFIX "")
-+ENDIF(NOT LIB_SUFFIX)
- if(NOT VTK_INSTALL_RUNTIME_DIR)
- set(VTK_INSTALL_RUNTIME_DIR bin)
- endif()
- if(NOT VTK_INSTALL_LIBRARY_DIR)
-- set(VTK_INSTALL_LIBRARY_DIR lib)
-+ set(VTK_INSTALL_LIBRARY_DIR lib${LIB_SUFFIX})
- endif()
- if(NOT VTK_INSTALL_ARCHIVE_DIR)
-- set(VTK_INSTALL_ARCHIVE_DIR lib)
-+ set(VTK_INSTALL_ARCHIVE_DIR lib${LIB_SUFFIX})
- endif()
- if(NOT VTK_INSTALL_INCLUDE_DIR)
- set(VTK_INSTALL_INCLUDE_DIR include/vtk-${VTK_MAJOR_VERSION}.${VTK_MINOR_VERSION})
-@@ -97,14 +100,14 @@
- set(VTK_INSTALL_DOC_DIR share/doc/vtk-${VTK_MAJOR_VERSION}.${VTK_MINOR_VERSION})
- endif()
- if(NOT VTK_INSTALL_PACKAGE_DIR)
-- set(VTK_INSTALL_PACKAGE_DIR "lib/cmake/vtk-${VTK_MAJOR_VERSION}.${VTK_MINOR_VERSION}")
-+ set(VTK_INSTALL_PACKAGE_DIR "lib${LIB_SUFFIX}/cmake/vtk-${VTK_MAJOR_VERSION}.${VTK_MINOR_VERSION}")
- endif()
- if(NOT VTK_INSTALL_DOXYGEN_DIR)
- set(VTK_INSTALL_DOXYGEN_DIR ${VTK_INSTALL_DOC_DIR}/doxygen)
- endif()
- if(NOT VTK_INSTALL_TCL_DIR)
-- # tclsh searches <prefix>/lib/tcltk and its subdirectories for pkgIndex.tcl files
-- set(VTK_INSTALL_TCL_DIR lib/tcltk/vtk-${VTK_MAJOR_VERSION}.${VTK_MINOR_VERSION})
-+ # tclsh searches <prefix>/lib${LIB_SUFFIX}/tcltk and its subdirectories for pkgIndex.tcl files
-+ set(VTK_INSTALL_TCL_DIR lib${LIB_SUFFIX}/tcltk/vtk-${VTK_MAJOR_VERSION}.${VTK_MINOR_VERSION})
- endif()
- if(NOT VTK_INSTALL_EXPORT_NAME)
- set(VTK_INSTALL_EXPORT_NAME VTKTargets)