From a5711585ca1e99533578410e543a2b3ad30ffb69 Mon Sep 17 00:00:00 2001 From: Bernd Waibel Date: Sat, 17 Sep 2022 11:10:14 +0200 Subject: media-gfx/blender: add optix support to live ebuild Signed-off-by: Bernd Waibel Closes: https://github.com/gentoo/gentoo/pull/27303 Signed-off-by: Ionen Wolkens --- media-gfx/blender/blender-9999.ebuild | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) (limited to 'media-gfx/blender') diff --git a/media-gfx/blender/blender-9999.ebuild b/media-gfx/blender/blender-9999.ebuild index 48a7c50cf696..0426748b3a70 100644 --- a/media-gfx/blender/blender-9999.ebuild +++ b/media-gfx/blender/blender-9999.ebuild @@ -28,7 +28,8 @@ IUSE="+bullet +dds +fluid +openexr +tbb \ alembic collada +color-management cuda +cycles \ debug doc +embree +ffmpeg +fftw +gmp headless jack jemalloc jpeg2k \ man +nanovdb ndof nls openal +oidn +openimageio +openmp +opensubdiv \ - +openvdb +osl +pdf +potrace +pugixml pulseaudio sdl +sndfile test +tiff valgrind" + +openvdb optix +osl +pdf +potrace +pugixml pulseaudio sdl +sndfile \ + test +tiff valgrind" RESTRICT="!test? ( test )" REQUIRED_USE="${PYTHON_REQUIRED_USE} @@ -37,6 +38,7 @@ REQUIRED_USE="${PYTHON_REQUIRED_USE} cycles? ( openexr tiff openimageio ) fluid? ( tbb ) openvdb? ( tbb ) + optix? ( cuda ) osl? ( cycles ) test? ( color-management )" @@ -93,6 +95,7 @@ RDEPEND="${PYTHON_DEPS} >=media-gfx/openvdb-9.0.0:=[nanovdb?] dev-libs/c-blosc:= ) + optix? ( =media-libs/osl-1.11.16.0-r3:= ) pdf? ( media-libs/libharu ) potrace? ( media-gfx/potrace ) @@ -217,6 +220,7 @@ src_configure() { -DWITH_CXX_GUARDEDALLOC=$(usex debug) -DWITH_CYCLES=$(usex cycles) -DWITH_CYCLES_DEVICE_CUDA=$(usex cuda TRUE FALSE) + -DWITH_CYCLES_DEVICE_OPTIX=$(usex optix) -DWITH_CYCLES_EMBREE=$(usex embree) -DWITH_CYCLES_OSL=$(usex osl) -DWITH_CYCLES_STANDALONE=OFF @@ -264,6 +268,13 @@ src_configure() { -DWITH_XR_OPENXR=OFF ) + if use optix; then + mycmakeargs+=( + -DCYCLES_RUNTIME_OPTIX_ROOT_DIR="${EPREFIX}"/opt/optix + -DOPTIX_ROOT_DIR="${EPREFIX}"/opt/optix + ) + fi + append-flags $(usex debug '-DDEBUG' '-DNDEBUG') if tc-is-gcc ; then @@ -286,8 +297,8 @@ src_test() { blender_get_version # Define custom blender data/script file paths not be able to find them otherwise during testing. # (Because the data is in the image directory and it will default to look in /usr/share) - export BLENDER_SYSTEM_SCRIPTS=${ED}/usr/share/blender/${BV}/scripts - export BLENDER_SYSTEM_DATAFILES=${ED}/usr/share/blender/${BV}/datafiles + export BLENDER_SYSTEM_SCRIPTS="${ED}"/usr/share/blender/${BV}/scripts + export BLENDER_SYSTEM_DATAFILES="${ED}"/usr/share/blender/${BV}/datafiles # Sanity check that the script and datafile path is valid. # If they are not vaild, blender will fallback to the default path which is not what we want. -- cgit v1.2.3-65-gdbad