diff options
author | David Spencer <baildon.research@googlemail.com> | 2016-07-14 12:17:17 +0100 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2016-07-17 07:49:55 +0700 |
commit | b23225c6b1039e1ec16ab3e4367b9f35e8fc0339 (patch) | |
tree | 977b019d056cd84b4654b4a6e97c8a6e9c598d9d /libraries/VTK/VTK.SlackBuild | |
parent | e6b2c607c7aef73402759625daf757c8d2195be8 (diff) |
libraries/VTK: Moved to /usr from /opt.
Signed-off-by: David Spencer <baildon.research@googlemail.com>
Diffstat (limited to 'libraries/VTK/VTK.SlackBuild')
-rw-r--r-- | libraries/VTK/VTK.SlackBuild | 40 |
1 files changed, 23 insertions, 17 deletions
diff --git a/libraries/VTK/VTK.SlackBuild b/libraries/VTK/VTK.SlackBuild index 1a1c905e7df6d..88497e9a2afa7 100644 --- a/libraries/VTK/VTK.SlackBuild +++ b/libraries/VTK/VTK.SlackBuild @@ -26,10 +26,11 @@ # 2014-02-16 Update to 6.1.0 # 2014-11-16 Support VTK features # 2015-12-12 Update to 6.3.0, use external deps, move to /opt +# 2016-07-14 Move back to /usr PRGNAM=VTK VERSION=${VERSION:-6.3.0} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then @@ -62,13 +63,13 @@ fi # configure VTK features # (defaults suitable for OpenCASCADE, it's the only SBo package that depends on VTK) group_imaging="" ; [ "${IMAGING:-yes}" != "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_mpi="" ; [ "${MPI:-no}" != "no" ] && group_mpi="-DVTK_Group_MPI=true" +group_qt="" ; [ "${QT:-yes}" != "no" ] && group_qt="-DVTK_Group_Qt=true" group_tk="" ; [ "${TK:-yes}" != "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" +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:-yes}" != "no" ] && wrap_tcl="-DVTK_WRAP_TCL=true" set -e @@ -88,9 +89,9 @@ find -L . \ # patch CMakefile first for lib64 issue patch -p0 <$CWD/patch-handle-64bit.diff +# patch for gdal-2.x (gdal is an optional dep) - thanks to Arch +patch -p1 <$CWD/patch-gdal2.diff -# -DCMAKE_INSTALL_PREFIX=/opt -# Installing to /usr creates /usr/plugins, /usr/src/vtk, /usr/lib64/www :-( # -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_* @@ -104,11 +105,11 @@ cd build cmake \ -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \ -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \ - -DCMAKE_INSTALL_PREFIX=/opt/$PRGNAM \ + -DCMAKE_INSTALL_PREFIX=/usr \ -DLIB_SUFFIX=$LIBDIRSUFFIX \ -DBUILD_SHARED_LIBS=ON \ -DVTK_CUSTOM_LIBRARY_SUFFIX="" \ - -DVTK_INSTALL_INCLUDE_DIR:PATH=include \ + -DVTK_INSTALL_INCLUDE_DIR:PATH=include/VTK \ $group_imaging \ $group_mpi \ $group_qt \ @@ -134,21 +135,26 @@ cd build make install DESTDIR=$PKG cd .. -mkdir -p $PKG/usr/lib$LIBDIRSUFFIX/python2.7/site-packages/ -mv \ - $PKG/opt/VTK/lib$LIBDIRSUFFIX/python2.7/site-packages/vtk \ - $PKG/usr/lib$LIBDIRSUFFIX/python2.7/site-packages/ -rm -rf $PKG/opt/VTK/lib$LIBDIRSUFFIX/python2.7 - find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true +mkdir -p $PKG/usr/lib${LIBDIRSUFFIX}/qt +mv \ + $PKG/usr/plugins/ \ + $PKG/usr/lib${LIBDIRSUFFIX}/qt + mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION cp -a \ CONTRIBUTING.md Copyright.txt README.md \ $PKG/usr/doc/$PRGNAM-$VERSION +mv \ + $PKG/usr/share/doc/vtk-6.3/verdict/ \ + $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild +rm -rf $PKG/usr/share/doc +rm -rf $PKG/usr/share/cmake + mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc |