diff options
Diffstat (limited to 'libraries/OpenSceneGraph/OpenSceneGraph.SlackBuild')
-rw-r--r-- | libraries/OpenSceneGraph/OpenSceneGraph.SlackBuild | 29 |
1 files changed, 16 insertions, 13 deletions
diff --git a/libraries/OpenSceneGraph/OpenSceneGraph.SlackBuild b/libraries/OpenSceneGraph/OpenSceneGraph.SlackBuild index ba5dcda856f4..a7319c1e01f2 100644 --- a/libraries/OpenSceneGraph/OpenSceneGraph.SlackBuild +++ b/libraries/OpenSceneGraph/OpenSceneGraph.SlackBuild @@ -4,10 +4,11 @@ # Written by Aleksandar Samardzic <asamardzic@gmail.com> # Maintained by Jordan Evans <jordanevans19@gmail.com> +# Maintained 2018 by Christoph Willing <chris.willing@linux.com> PRGNAM=OpenSceneGraph -VERSION=${VERSION:-3.4.0} -BUILD=${BUILD:-2} +VERSION=${VERSION:-3.5.5} +BUILD=${BUILD:-1} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then @@ -37,14 +38,18 @@ else LIBDIRSUFFIX="" fi +# Support OpenCASCADE, if installed +occ=""; ls -l /var/log/packages/OpenCASCADE* 2>/dev/null 1>/dev/null +[ $? -eq 0 ] && occ="-DOPENCASCADE_INCLUDE_DIR=/opt/OpenCASCADE/inc -DOPENCASCADE_LIBRARY_TYPE=Shared" + set -e rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP rm -rf $PRGNAM-$VERSION -unzip $CWD/$PRGNAM-$VERSION.zip -cd $PRGNAM-$VERSION +tar xf $CWD/$PRGNAM-$VERSION.tar.gz +cd $PRGNAM-$PRGNAM-$VERSION chown -R root:root . find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ @@ -52,18 +57,16 @@ 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 {} \; -# Thanks to ARCH -patch -p2 < $CWD/ffmpeg3.patch - mkdir -p build cd build - cmake \ + cmake .. \ -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \ - -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \ + -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS -std=c++11" \ -DCMAKE_INSTALL_PREFIX=/usr \ - -DLIB_SUFFIX=${LIBDIRSUFFIX} \ - -DMAN_INSTALL_DIR=/usr/man \ - -DCMAKE_BUILD_TYPE=Release .. + -DCMAKE_BUILD_TYPE=Release \ + $occ \ + -DBUILD_OSG_EXAMPLES=ON \ + make make install DESTDIR=$PKG cd .. @@ -72,7 +75,7 @@ find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | gr | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp -a AUTHORS.txt ChangeLog LICENSE.txt NEWS.txt README.txt $PKG/usr/doc/$PRGNAM-$VERSION +cp -a AUTHORS.txt ChangeLog LICENSE.txt NEWS.txt README* $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild mkdir -p $PKG/install |