diff options
Diffstat (limited to 'graphics/Blender/Blender.SlackBuild')
-rw-r--r-- | graphics/Blender/Blender.SlackBuild | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/graphics/Blender/Blender.SlackBuild b/graphics/Blender/Blender.SlackBuild index 06d9917ec573d..4d8d8cb152bf2 100644 --- a/graphics/Blender/Blender.SlackBuild +++ b/graphics/Blender/Blender.SlackBuild @@ -2,7 +2,7 @@ # Slackware build script for Blender -# Copyright 2015-2020 Christoph Willing, Brisbane Australia +# Copyright 2015-2021 Christoph Willing, Brisbane Australia # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -24,7 +24,7 @@ PRGNAM=Blender VERSION=${VERSION:-2.83.8} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} SRCNAM=blender @@ -69,6 +69,16 @@ if [ -d /usr/include/cuda ]; then fi fi +embree="" +if [ -d /usr/include/embree3 ]; then + # If embree is installed, assume we want to use it + embree="-DWITH_CYCLES_EMBREE=ON" + # However disable embree if requested by e.g. EMBREE=no + if [ ${EMBREE:-yes} != "yes" ]; then + embree="-DWITH_CYCLES_EMBREE=OFF" + fi +fi + set -e rm -rf $PKG @@ -77,6 +87,7 @@ cd $TMP rm -rf $SRCNAM-$VERSION tar xvf $CWD/$SRCNAM-$VERSION.tar.xz cd $SRCNAM-$VERSION +patch -p0 < $CWD/01_FindEmbree_so.diff chown -R root:root . find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ @@ -115,6 +126,7 @@ cd build -DWITH_SDL_DYNLOAD:BOOL=ON \ -DCMAKE_BUILD_TYPE=Release \ $cuda \ + $embree \ make make install DESTDIR=$PKG |