commit:     9e55be1fc995548bf3b729c2f9cd6f2a161b8537
Author:     Paul Zander <negril.nx+gentoo <AT> gmail <DOT> com>
AuthorDate: Mon Jun  3 12:08:36 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat Jun 29 16:49:12 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9e55be1f

media-libs/osl: add 1.13.10.0

Closes: https://bugs.gentoo.org/928425
Closes: https://bugs.gentoo.org/928422
Closes: https://bugs.gentoo.org/922964
Signed-off-by: Paul Zander <negril.nx+gentoo <AT> gmail.com>
Signed-off-by: Sam James <sam <AT> gentoo.org>

 ...blender-9999.ebuild => blender-4.1.1-r1.ebuild} |  15 +-
 media-gfx/blender/blender-9999.ebuild              |  15 +-
 media-libs/osl/Manifest                            |   1 +
 media-libs/osl/osl-1.12.14.0-r1.ebuild             |   8 +-
 .../osl/{osl-9999.ebuild => osl-1.13.10.0.ebuild}  | 219 +++++----------------
 media-libs/osl/osl-9999.ebuild                     | 219 +++++----------------
 6 files changed, 128 insertions(+), 349 deletions(-)

diff --git a/media-gfx/blender/blender-9999.ebuild 
b/media-gfx/blender/blender-4.1.1-r1.ebuild
similarity index 98%
copy from media-gfx/blender/blender-9999.ebuild
copy to media-gfx/blender/blender-4.1.1-r1.ebuild
index 94e2599fa018..b4d0fa864c54 100644
--- a/media-gfx/blender/blender-9999.ebuild
+++ b/media-gfx/blender/blender-4.1.1-r1.ebuild
@@ -5,7 +5,7 @@ EAPI=8
 
 PYTHON_COMPAT=( python3_{11..12} )
 # matches media-libs/osl
-LLVM_COMPAT=( {15..17} )
+LLVM_COMPAT=( {15..18} )
 
 inherit check-reqs cmake cuda flag-o-matic llvm-r1 pax-utils python-single-r1 
toolchain-funcs xdg-utils
 
@@ -109,11 +109,8 @@ RDEPEND="${PYTHON_DEPS}
        )
        optix? ( dev-libs/optix )
        osl? (
-               >=media-libs/osl-1.13:=
-               $(llvm_gen_dep '
-                       >=media-libs/osl-1.13[llvm_slot_${LLVM_SLOT}]
-                       media-libs/mesa[llvm_slot_${LLVM_SLOT}]
-               ')
+               >=media-libs/osl-1.13:=[${LLVM_USEDEP}]
+               media-libs/mesa[${LLVM_USEDEP}]
        )
        pdf? ( media-libs/libharu )
        potrace? ( media-gfx/potrace )
@@ -207,7 +204,11 @@ blender_get_version() {
 pkg_pretend() {
        blender_check_requirements
 
-       use oneapi && einfo "The Intel oneAPI support is rudimentary. Please 
report any bugs you find to https://bugs.gentoo.org/";
+       if use oneapi; then
+               einfo "The Intel oneAPI support is rudimentary."
+               einfo ""
+               einfo "Please report any bugs you find to 
https://bugs.gentoo.org/";
+       fi
 }
 
 pkg_setup() {

diff --git a/media-gfx/blender/blender-9999.ebuild 
b/media-gfx/blender/blender-9999.ebuild
index 94e2599fa018..b4d0fa864c54 100644
--- a/media-gfx/blender/blender-9999.ebuild
+++ b/media-gfx/blender/blender-9999.ebuild
@@ -5,7 +5,7 @@ EAPI=8
 
 PYTHON_COMPAT=( python3_{11..12} )
 # matches media-libs/osl
-LLVM_COMPAT=( {15..17} )
+LLVM_COMPAT=( {15..18} )
 
 inherit check-reqs cmake cuda flag-o-matic llvm-r1 pax-utils python-single-r1 
toolchain-funcs xdg-utils
 
@@ -109,11 +109,8 @@ RDEPEND="${PYTHON_DEPS}
        )
        optix? ( dev-libs/optix )
        osl? (
-               >=media-libs/osl-1.13:=
-               $(llvm_gen_dep '
-                       >=media-libs/osl-1.13[llvm_slot_${LLVM_SLOT}]
-                       media-libs/mesa[llvm_slot_${LLVM_SLOT}]
-               ')
+               >=media-libs/osl-1.13:=[${LLVM_USEDEP}]
+               media-libs/mesa[${LLVM_USEDEP}]
        )
        pdf? ( media-libs/libharu )
        potrace? ( media-gfx/potrace )
@@ -207,7 +204,11 @@ blender_get_version() {
 pkg_pretend() {
        blender_check_requirements
 
-       use oneapi && einfo "The Intel oneAPI support is rudimentary. Please 
report any bugs you find to https://bugs.gentoo.org/";
+       if use oneapi; then
+               einfo "The Intel oneAPI support is rudimentary."
+               einfo ""
+               einfo "Please report any bugs you find to 
https://bugs.gentoo.org/";
+       fi
 }
 
 pkg_setup() {

diff --git a/media-libs/osl/Manifest b/media-libs/osl/Manifest
index 5fb6518260ba..fcebc31179bc 100644
--- a/media-libs/osl/Manifest
+++ b/media-libs/osl/Manifest
@@ -3,3 +3,4 @@ DIST osl-1.12.13.0.tar.gz 20286745 BLAKE2B 
75a2a5d10000ba26cd11463dde710d5be3b8b
 DIST osl-1.12.14.0.tar.gz 20555853 BLAKE2B 
4f6bc2084e4c1b25e707a37830961f20926e6ab5cb915c763cbd8126127e70f6368832077729ab5e044f573e8c38c4afb413eff8adccee5ea1ae96cb9be43b6e
 SHA512 
51641e58fb0bba042853e3976c104decc788f1b1d3ec2e33a3f5504b11b05950dc38766ffb066b0f76edc4e0a8829d6b7dd408d9288b74d69380395b1d991bd5
 DIST osl-1.12.7.0.tar.gz 20250356 BLAKE2B 
a9398243546b1bfc1e3f9602f6112a72a8e7cb6ace54e93d0e5f30d943474e82c3317596597d6a09e0f2cf04b1b21f05c31a2357e3d667d710cd2aa340f5fd63
 SHA512 
ec0391dfc95140fee4fa8332991cdcb0978dafc436f3e07d0293e2baa2014b8765e6b60631ae5a8bbd6e16dbcf37f04c076d7d6b2d8bfa58b78471f0d92c433f
 DIST osl-1.13.7.0.tar.gz 21774349 BLAKE2B 
1fd731f14b8dce948d7995efadb63eec8ce028ed6b095db391d2dfedcbbd62ca3aad9cd5d7d40f94c9e358f952d841899103467a2f81b12a605ae8c8436a16ff
 SHA512 
15ffc6a5eed44141672af3d7ddab5d97abacad2062cddb35ef2a8484538a9a9a86cbd7e7170deafcefd3b69df764bfd207685603ca17a2fbff4299ccd1afe569
+DIST osl-1.13.10.0.tar.gz 21776721 BLAKE2B 
6b40adcf50403292003ae8216e60328d5af6d25bf22cd241aeb4f99b1d39c628c78fe1bc8372226c984ca38b6e08427525f12dc38e5b6d3355de02cbc71f1b7b
 SHA512 
f005b8797a7bb882bcdf4fd644551d42c150956baa8dd9deff39ff1121321f33b8e144a9a96ac940ae6bf60985c6131457131baa87c73c2b498298aaa77c3c7d

diff --git a/media-libs/osl/osl-1.12.14.0-r1.ebuild 
b/media-libs/osl/osl-1.12.14.0-r1.ebuild
index 50363e61e508..628b4123b45d 100644
--- a/media-libs/osl/osl-1.12.14.0-r1.ebuild
+++ b/media-libs/osl/osl-1.12.14.0-r1.ebuild
@@ -173,7 +173,6 @@ src_configure() {
                -DSTOP_ON_WARNING="no"
                -DUSE_PARTIO="$(usex partio)"
                -DUSE_PYTHON="$(usex python)"
-               -DPYTHON_VERSION="${EPYTHON/python}"
                -DUSE_SIMD="$(IFS=","; echo "${mysimd[*]}")"
                -DUSE_BATCHED="$(IFS=","; echo "${mybatched[*]}")"
                -DUSE_LIBCPLUSPLUS="$(usex libcxx)"
@@ -198,6 +197,13 @@ src_configure() {
                )
        fi
 
+       if use python; then
+               mycmakeargs+=(
+                       "-DPYTHON_VERSION=${EPYTHON#python}"
+                       "-DPYTHON_SITE_DIR=$(python_get_sitedir)"
+               )
+       fi
+
        cmake_src_configure
 }
 

diff --git a/media-libs/osl/osl-9999.ebuild 
b/media-libs/osl/osl-1.13.10.0.ebuild
similarity index 57%
copy from media-libs/osl/osl-9999.ebuild
copy to media-libs/osl/osl-1.13.10.0.ebuild
index 68654d760dc8..9d66a33c3e3d 100644
--- a/media-libs/osl/osl-9999.ebuild
+++ b/media-libs/osl/osl-1.13.10.0.ebuild
@@ -6,7 +6,7 @@ EAPI=8
 PYTHON_COMPAT=( python3_{10..12} )
 
 # Check this on updates
-LLVM_COMPAT=( {15..17} )
+LLVM_COMPAT=( {15..18} )
 
 inherit cmake cuda flag-o-matic llvm-r1 toolchain-funcs python-single-r1
 
@@ -24,7 +24,7 @@ else
 fi
 
 LICENSE="BSD"
-SLOT="0/$(ver_cut 1-3)"
+SLOT="0/$(ver_cut 1-2)" # based on SONAME
 
 X86_CPU_FEATURES=(
        sse2:sse2 sse3:sse3 ssse3:ssse3 sse4_1:sse4.1 sse4_2:sse4.2
@@ -33,7 +33,9 @@ X86_CPU_FEATURES=(
 CPU_FEATURES=( "${X86_CPU_FEATURES[@]/#/cpu_flags_x86_}" )
 
 IUSE="doc gui libcxx nofma optix partio qt6 test ${CPU_FEATURES[*]%:*} python"
+
 RESTRICT="!test? ( test )"
+
 REQUIRED_USE="${PYTHON_REQUIRED_USE}"
 
 # TODO optix
@@ -69,7 +71,12 @@ RDEPEND="
        )
 "
 
-DEPEND="${RDEPEND}"
+DEPEND="${RDEPEND}
+       dev-util/patchelf
+       test? (
+               media-fonts/droid
+       )
+"
 BDEPEND="
        sys-devel/bison
        sys-devel/flex
@@ -130,25 +137,24 @@ src_configure() {
                                        "b8_AVX512_noFMA"
                                        "b16_AVX512_noFMA"
                                )
-                       else
-                               mybatched+=(
-                                       "b8_AVX512"
-                                       "b16_AVX512"
-                               )
                        fi
+                       mybatched+=(
+                               "b8_AVX512"
+                               "b16_AVX512"
+                       )
                fi
                if use cpu_flags_x86_avx2 ; then
                        if use nofma; then
                                mybatched+=(
                                        "b8_AVX2_noFMA"
                                )
-                       else
-                               mybatched+=(
-                                       "b8_AVX2"
-                               )
                        fi
+                       mybatched+=(
+                               "b8_AVX2"
+                       )
                fi
-       elif use cpu_flags_x86_avx ; then
+       fi
+       if use cpu_flags_x86_avx ; then
                mybatched+=(
                        "b8_AVX"
                )
@@ -167,7 +173,6 @@ src_configure() {
 
        local mycmakeargs=(
                -DCMAKE_POLICY_DEFAULT_CMP0146="OLD" # BUG FindCUDA
-               -DCMAKE_POLICY_DEFAULT_CMP0148="OLD" # BUG FindPythonInterp
 
                # std::tuple_size_v is c++17
                -DCMAKE_CXX_STANDARD="17"
@@ -180,7 +185,6 @@ src_configure() {
                -DSTOP_ON_WARNING="no"
                -DUSE_PARTIO="$(usex partio)"
                -DUSE_PYTHON="$(usex python)"
-               -DPYTHON_VERSION="${EPYTHON/python}"
                -DUSE_SIMD="$(IFS=","; echo "${mysimd[*]}")"
                -DUSE_BATCHED="$(IFS=","; echo "${mybatched[*]}")"
                -DUSE_LIBCPLUSPLUS="$(usex libcxx)"
@@ -219,6 +223,13 @@ src_configure() {
                )
        fi
 
+       if use python; then
+               mycmakeargs+=(
+                       "-DPYTHON_VERSION=${EPYTHON#python}"
+                       "-DPYTHON_SITE_DIR=$(python_get_sitedir)"
+               )
+       fi
+
        cmake_src_configure
 }
 
@@ -245,166 +256,24 @@ src_test() {
        fi
 
        CMAKE_SKIP_TESTS=(
-               "broken"
+               "-broken$"
                "^render"
 
                # broken with in-tree <=dev-libs/optix-7.5.0 and out of date
                "^example-cuda$"
 
                # outright fail
+               "^testoptix.optix.opt$"
+               "^testoptix-noise.optix.opt$"
+               "^testoptix-reparam.optix.opt$"
                "^transform-reg.regress.batched.opt$"
-
-               # SIGABRT similar to 
https://github.com/AcademySoftwareFoundation/OpenShadingLanguage/issues/1363
-               "^derivs.opt.rs_bitcode$"
-               "^geomath.batched$"
-               "^matrix.batched$"
-               "^matrix.batched.opt$"
                "^spline-reg.regress.batched.opt$"
-               "^transformc.batched$"
-       )
 
-       # These only fail inside sandbox
-       if [[ "${OSL_OPTIONAL_TESTS}" != "true" ]]; then
-               CMAKE_SKIP_TESTS+=(
-                       # TODO: investigate failures
-                       # SIGABRT similar to 
https://github.com/AcademySoftwareFoundation/OpenShadingLanguage/issues/1363
-                       "^andor-reg.regress.batched.opt$"
-                       "^arithmetic-reg.regress.batched.opt$"
-                       "^array-assign-reg.regress.batched.opt$"
-                       "^array-copy-reg.regress.batched.opt$"
-                       "^array-length-reg.regress.batched$"
-                       "^closure-parameters.batched$"
-                       "^closure-parameters.batched.opt$"
-                       "^closure.batched$"
-                       "^closure.batched.opt$"
-                       "^debug-uninit$"
-                       "^debug-uninit.batched$"
-                       "^debug-uninit.batched.opt$"
-                       "^debug-uninit.opt$"
-                       "^debug-uninit.opt.rs_bitcode$"
-                       "^derivs$"
-                       "^derivs.batched$"
-                       "^derivs.batched.opt$"
-                       "^derivs.opt$"
-                       "^exponential$"
-                       "^exponential.opt$"
-                       "^exponential.opt.rs_bitcode$"
-                       "^filterwidth-reg.regress.batched.opt$"
-                       "^geomath$"
-                       "^geomath.batched.opt$"
-                       "^geomath.opt$"
-                       "^geomath.opt.rs_bitcode$"
-                       "^getattribute-camera.batched$"
-                       "^getattribute-camera.batched.opt$"
-                       "^getattribute-shader.batched.opt$"
-                       "^gettextureinfo-reg.regress.batched.opt$"
-                       "^gettextureinfo-udim-reg.regress.batched.opt$"
-                       "^gettextureinfo.batched$"
-                       "^hyperb.batched.opt$"
-                       "^hyperb.opt$"
-                       "^hyperb.opt.rs_bitcode$"
-                       "^initlist.batched$"
-                       "^initlist.batched.opt$"
-                       "^linearstep.batched$"
-                       "^linearstep.batched.opt$"
-                       "^loop.batched$"
-                       "^loop.batched.opt$"
-                       "^matrix$"
-                       "^matrix-compref-reg.regress.batched.opt$"
-                       "^matrix-reg.regress.rsbitcode.opt$"
-                       "^matrix.opt$"
-                       "^matrix.opt.rs_bitcode$"
-                       "^matrix.rsbitcode.opt$"
-                       "^message-no-closure.batched$"
-                       "^message-no-closure.batched.opt$"
-                       "^message-reg.regress.batched.opt$"
-                       "^miscmath$"
-                       "^miscmath.batched$"
-                       "^miscmath.batched.opt$"
-                       "^miscmath.opt$"
-                       "^miscmath.opt.rs_bitcode$"
-                       "^noise-cell.batched$"
-                       "^noise-gabor-reg.regress.batched.opt$"
-                       "^noise-gabor.batched$"
-                       "^noise-gabor.batched.opt$"
-                       "^noise-generic.batched$"
-                       "^noise-generic.batched.opt$"
-                       "^noise-perlin.batched$"
-                       "^noise-perlin.batched.opt$"
-                       "^noise-reg.regress.batched.opt$"
-                       "^noise-simplex.batched$"
-                       "^noise-simplex.batched.opt$"
-                       "^noise.batched$"
-                       "^opt-warnings.batched$"
-                       "^opt-warnings.batched.opt$"
-                       "^pnoise-cell.batched$"
-                       "^pnoise-gabor.batched$"
-                       "^pnoise-gabor.batched.opt$"
-                       "^pnoise-generic.batched$"
-                       "^pnoise-generic.batched.opt$"
-                       "^pnoise-perlin.batched$"
-                       "^pnoise-perlin.batched.opt$"
-                       "^pnoise-reg.regress.batched.opt$"
-                       "^pnoise.batched$"
-                       "^pointcloud.batched$"
-                       "^pointcloud.batched.opt$"
-                       "^regex-reg.regress.batched.opt$"
-                       "^select.batched$"
-                       "^select.batched.opt$"
-                       "^shaderglobals.batched$"
-                       "^shaderglobals.batched.opt$"
-                       "^smoothstep-reg.regress.batched.opt$"
-                       "^spline-derivbug.batched$"
-                       "^spline-derivbug.batched.opt$"
-                       "^spline.batched$"
-                       "^spline.batched.opt$"
-                       "^splineinverse-ident.batched$"
-                       "^splineinverse-ident.batched.opt$"
-                       "^split-reg.regress.batched.opt$"
-                       "^string$"
-                       "^string-reg.regress.batched.opt$"
-                       "^string.batched$"
-                       "^string.batched.opt$"
-                       "^string.opt$"
-                       "^string.opt.rs_bitcode$"
-                       "^struct-array-mixture.batched$"
-                       "^struct-array-mixture.batched.opt$"
-                       "^struct.batched$"
-                       "^test-fmt-matrixcolor.opt.rs_bitcode$"
-                       "^testoptix-noise.optix.opt$"
-                       "^testoptix-reparam.optix.opt$"
-                       "^texture-environment-opts-reg.regress.batched.opt$"
-                       "^texture-opts-reg.regress.batched.opt$"
-                       "^texture-wrap.batched$"
-                       "^texture-wrap.batched.opt$"
-                       "^transcendental-reg.regress.batched.opt$"
-                       "^transform$"
-                       "^transform.batched$"
-                       "^transform.batched.opt$"
-                       "^transform.opt$"
-                       "^transform.opt.rs_bitcode$"
-                       "^transformc$"
-                       "^transformc.batched.opt$"
-                       "^transformc.opt$"
-                       "^transformc.opt.rs_bitcode$"
-                       "^transformc.rsbitcode.opt$"
-                       "^trig$"
-                       "^trig-reg.regress.batched.opt$"
-                       "^trig.batched$"
-                       "^trig.batched.opt$"
-                       "^trig.opt$"
-                       "^trig.opt.rs_bitcode$"
-                       "^vecctr.batched$"
-                       "^vecctr.batched.opt$"
-                       "^vector$"
-                       "^vector-reg.regress.batched.opt$"
-                       "^vector.opt$"
-                       "^vector.opt.rs_bitcode$"
-                       "^xml-reg.regress.batched.opt$"
-                       # diff
-                       "^testoptix.optix.opt$"
-               )
-       fi
+               # doesn't handle parameters
+               "^osl-imageio$"
+               "^osl-imageio.opt$"
+               "^osl-imageio.opt.rs_bitcode$"
+       )
 
        myctestargs=(
                # src/build-scripts/ci-test.bash
@@ -412,7 +281,7 @@ src_test() {
        )
 
        local -x DEBUG CXXFLAGS LD_LIBRARY_PATH DIR OSL_DIR OSL_SOURCE_DIR 
PYTHONPATH
-       DEBUG=1 # doubles the floating point tolerance
+       DEBUG=1 # doubles the floating point tolerance so we avoid FMA related 
issues
        CXXFLAGS="-I${T}/usr/include"
        LD_LIBRARY_PATH="${T}/usr/$(get_libdir)"
        OSL_DIR="${T}/usr/$(get_libdir)/cmake/OSL"
@@ -424,6 +293,10 @@ src_test() {
 
        cmake_src_test
 
+       einfo ""
+       einfo "testing render tests in isolation"
+       einfo ""
+
        CMAKE_SKIP_TESTS=(
                "^render-background$"
                "^render-mx-furnace-sheen$"
@@ -445,3 +318,15 @@ src_test() {
 
        cmake_src_test
 }
+
+src_install() {
+       cmake_src_install
+
+       if [[ -d "${ED}/usr/build-scripts" ]]; then
+               rm -rf "${ED}/usr/build-scripts" || die
+       fi
+
+       for batched_lib in "${ED}/usr/$(get_libdir)/lib_"*"_oslexec.so"; do
+               patchelf --set-soname "$(basename "${batched_lib}")" 
"${batched_lib}" || die
+       done
+}

diff --git a/media-libs/osl/osl-9999.ebuild b/media-libs/osl/osl-9999.ebuild
index 68654d760dc8..9d66a33c3e3d 100644
--- a/media-libs/osl/osl-9999.ebuild
+++ b/media-libs/osl/osl-9999.ebuild
@@ -6,7 +6,7 @@ EAPI=8
 PYTHON_COMPAT=( python3_{10..12} )
 
 # Check this on updates
-LLVM_COMPAT=( {15..17} )
+LLVM_COMPAT=( {15..18} )
 
 inherit cmake cuda flag-o-matic llvm-r1 toolchain-funcs python-single-r1
 
@@ -24,7 +24,7 @@ else
 fi
 
 LICENSE="BSD"
-SLOT="0/$(ver_cut 1-3)"
+SLOT="0/$(ver_cut 1-2)" # based on SONAME
 
 X86_CPU_FEATURES=(
        sse2:sse2 sse3:sse3 ssse3:ssse3 sse4_1:sse4.1 sse4_2:sse4.2
@@ -33,7 +33,9 @@ X86_CPU_FEATURES=(
 CPU_FEATURES=( "${X86_CPU_FEATURES[@]/#/cpu_flags_x86_}" )
 
 IUSE="doc gui libcxx nofma optix partio qt6 test ${CPU_FEATURES[*]%:*} python"
+
 RESTRICT="!test? ( test )"
+
 REQUIRED_USE="${PYTHON_REQUIRED_USE}"
 
 # TODO optix
@@ -69,7 +71,12 @@ RDEPEND="
        )
 "
 
-DEPEND="${RDEPEND}"
+DEPEND="${RDEPEND}
+       dev-util/patchelf
+       test? (
+               media-fonts/droid
+       )
+"
 BDEPEND="
        sys-devel/bison
        sys-devel/flex
@@ -130,25 +137,24 @@ src_configure() {
                                        "b8_AVX512_noFMA"
                                        "b16_AVX512_noFMA"
                                )
-                       else
-                               mybatched+=(
-                                       "b8_AVX512"
-                                       "b16_AVX512"
-                               )
                        fi
+                       mybatched+=(
+                               "b8_AVX512"
+                               "b16_AVX512"
+                       )
                fi
                if use cpu_flags_x86_avx2 ; then
                        if use nofma; then
                                mybatched+=(
                                        "b8_AVX2_noFMA"
                                )
-                       else
-                               mybatched+=(
-                                       "b8_AVX2"
-                               )
                        fi
+                       mybatched+=(
+                               "b8_AVX2"
+                       )
                fi
-       elif use cpu_flags_x86_avx ; then
+       fi
+       if use cpu_flags_x86_avx ; then
                mybatched+=(
                        "b8_AVX"
                )
@@ -167,7 +173,6 @@ src_configure() {
 
        local mycmakeargs=(
                -DCMAKE_POLICY_DEFAULT_CMP0146="OLD" # BUG FindCUDA
-               -DCMAKE_POLICY_DEFAULT_CMP0148="OLD" # BUG FindPythonInterp
 
                # std::tuple_size_v is c++17
                -DCMAKE_CXX_STANDARD="17"
@@ -180,7 +185,6 @@ src_configure() {
                -DSTOP_ON_WARNING="no"
                -DUSE_PARTIO="$(usex partio)"
                -DUSE_PYTHON="$(usex python)"
-               -DPYTHON_VERSION="${EPYTHON/python}"
                -DUSE_SIMD="$(IFS=","; echo "${mysimd[*]}")"
                -DUSE_BATCHED="$(IFS=","; echo "${mybatched[*]}")"
                -DUSE_LIBCPLUSPLUS="$(usex libcxx)"
@@ -219,6 +223,13 @@ src_configure() {
                )
        fi
 
+       if use python; then
+               mycmakeargs+=(
+                       "-DPYTHON_VERSION=${EPYTHON#python}"
+                       "-DPYTHON_SITE_DIR=$(python_get_sitedir)"
+               )
+       fi
+
        cmake_src_configure
 }
 
@@ -245,166 +256,24 @@ src_test() {
        fi
 
        CMAKE_SKIP_TESTS=(
-               "broken"
+               "-broken$"
                "^render"
 
                # broken with in-tree <=dev-libs/optix-7.5.0 and out of date
                "^example-cuda$"
 
                # outright fail
+               "^testoptix.optix.opt$"
+               "^testoptix-noise.optix.opt$"
+               "^testoptix-reparam.optix.opt$"
                "^transform-reg.regress.batched.opt$"
-
-               # SIGABRT similar to 
https://github.com/AcademySoftwareFoundation/OpenShadingLanguage/issues/1363
-               "^derivs.opt.rs_bitcode$"
-               "^geomath.batched$"
-               "^matrix.batched$"
-               "^matrix.batched.opt$"
                "^spline-reg.regress.batched.opt$"
-               "^transformc.batched$"
-       )
 
-       # These only fail inside sandbox
-       if [[ "${OSL_OPTIONAL_TESTS}" != "true" ]]; then
-               CMAKE_SKIP_TESTS+=(
-                       # TODO: investigate failures
-                       # SIGABRT similar to 
https://github.com/AcademySoftwareFoundation/OpenShadingLanguage/issues/1363
-                       "^andor-reg.regress.batched.opt$"
-                       "^arithmetic-reg.regress.batched.opt$"
-                       "^array-assign-reg.regress.batched.opt$"
-                       "^array-copy-reg.regress.batched.opt$"
-                       "^array-length-reg.regress.batched$"
-                       "^closure-parameters.batched$"
-                       "^closure-parameters.batched.opt$"
-                       "^closure.batched$"
-                       "^closure.batched.opt$"
-                       "^debug-uninit$"
-                       "^debug-uninit.batched$"
-                       "^debug-uninit.batched.opt$"
-                       "^debug-uninit.opt$"
-                       "^debug-uninit.opt.rs_bitcode$"
-                       "^derivs$"
-                       "^derivs.batched$"
-                       "^derivs.batched.opt$"
-                       "^derivs.opt$"
-                       "^exponential$"
-                       "^exponential.opt$"
-                       "^exponential.opt.rs_bitcode$"
-                       "^filterwidth-reg.regress.batched.opt$"
-                       "^geomath$"
-                       "^geomath.batched.opt$"
-                       "^geomath.opt$"
-                       "^geomath.opt.rs_bitcode$"
-                       "^getattribute-camera.batched$"
-                       "^getattribute-camera.batched.opt$"
-                       "^getattribute-shader.batched.opt$"
-                       "^gettextureinfo-reg.regress.batched.opt$"
-                       "^gettextureinfo-udim-reg.regress.batched.opt$"
-                       "^gettextureinfo.batched$"
-                       "^hyperb.batched.opt$"
-                       "^hyperb.opt$"
-                       "^hyperb.opt.rs_bitcode$"
-                       "^initlist.batched$"
-                       "^initlist.batched.opt$"
-                       "^linearstep.batched$"
-                       "^linearstep.batched.opt$"
-                       "^loop.batched$"
-                       "^loop.batched.opt$"
-                       "^matrix$"
-                       "^matrix-compref-reg.regress.batched.opt$"
-                       "^matrix-reg.regress.rsbitcode.opt$"
-                       "^matrix.opt$"
-                       "^matrix.opt.rs_bitcode$"
-                       "^matrix.rsbitcode.opt$"
-                       "^message-no-closure.batched$"
-                       "^message-no-closure.batched.opt$"
-                       "^message-reg.regress.batched.opt$"
-                       "^miscmath$"
-                       "^miscmath.batched$"
-                       "^miscmath.batched.opt$"
-                       "^miscmath.opt$"
-                       "^miscmath.opt.rs_bitcode$"
-                       "^noise-cell.batched$"
-                       "^noise-gabor-reg.regress.batched.opt$"
-                       "^noise-gabor.batched$"
-                       "^noise-gabor.batched.opt$"
-                       "^noise-generic.batched$"
-                       "^noise-generic.batched.opt$"
-                       "^noise-perlin.batched$"
-                       "^noise-perlin.batched.opt$"
-                       "^noise-reg.regress.batched.opt$"
-                       "^noise-simplex.batched$"
-                       "^noise-simplex.batched.opt$"
-                       "^noise.batched$"
-                       "^opt-warnings.batched$"
-                       "^opt-warnings.batched.opt$"
-                       "^pnoise-cell.batched$"
-                       "^pnoise-gabor.batched$"
-                       "^pnoise-gabor.batched.opt$"
-                       "^pnoise-generic.batched$"
-                       "^pnoise-generic.batched.opt$"
-                       "^pnoise-perlin.batched$"
-                       "^pnoise-perlin.batched.opt$"
-                       "^pnoise-reg.regress.batched.opt$"
-                       "^pnoise.batched$"
-                       "^pointcloud.batched$"
-                       "^pointcloud.batched.opt$"
-                       "^regex-reg.regress.batched.opt$"
-                       "^select.batched$"
-                       "^select.batched.opt$"
-                       "^shaderglobals.batched$"
-                       "^shaderglobals.batched.opt$"
-                       "^smoothstep-reg.regress.batched.opt$"
-                       "^spline-derivbug.batched$"
-                       "^spline-derivbug.batched.opt$"
-                       "^spline.batched$"
-                       "^spline.batched.opt$"
-                       "^splineinverse-ident.batched$"
-                       "^splineinverse-ident.batched.opt$"
-                       "^split-reg.regress.batched.opt$"
-                       "^string$"
-                       "^string-reg.regress.batched.opt$"
-                       "^string.batched$"
-                       "^string.batched.opt$"
-                       "^string.opt$"
-                       "^string.opt.rs_bitcode$"
-                       "^struct-array-mixture.batched$"
-                       "^struct-array-mixture.batched.opt$"
-                       "^struct.batched$"
-                       "^test-fmt-matrixcolor.opt.rs_bitcode$"
-                       "^testoptix-noise.optix.opt$"
-                       "^testoptix-reparam.optix.opt$"
-                       "^texture-environment-opts-reg.regress.batched.opt$"
-                       "^texture-opts-reg.regress.batched.opt$"
-                       "^texture-wrap.batched$"
-                       "^texture-wrap.batched.opt$"
-                       "^transcendental-reg.regress.batched.opt$"
-                       "^transform$"
-                       "^transform.batched$"
-                       "^transform.batched.opt$"
-                       "^transform.opt$"
-                       "^transform.opt.rs_bitcode$"
-                       "^transformc$"
-                       "^transformc.batched.opt$"
-                       "^transformc.opt$"
-                       "^transformc.opt.rs_bitcode$"
-                       "^transformc.rsbitcode.opt$"
-                       "^trig$"
-                       "^trig-reg.regress.batched.opt$"
-                       "^trig.batched$"
-                       "^trig.batched.opt$"
-                       "^trig.opt$"
-                       "^trig.opt.rs_bitcode$"
-                       "^vecctr.batched$"
-                       "^vecctr.batched.opt$"
-                       "^vector$"
-                       "^vector-reg.regress.batched.opt$"
-                       "^vector.opt$"
-                       "^vector.opt.rs_bitcode$"
-                       "^xml-reg.regress.batched.opt$"
-                       # diff
-                       "^testoptix.optix.opt$"
-               )
-       fi
+               # doesn't handle parameters
+               "^osl-imageio$"
+               "^osl-imageio.opt$"
+               "^osl-imageio.opt.rs_bitcode$"
+       )
 
        myctestargs=(
                # src/build-scripts/ci-test.bash
@@ -412,7 +281,7 @@ src_test() {
        )
 
        local -x DEBUG CXXFLAGS LD_LIBRARY_PATH DIR OSL_DIR OSL_SOURCE_DIR 
PYTHONPATH
-       DEBUG=1 # doubles the floating point tolerance
+       DEBUG=1 # doubles the floating point tolerance so we avoid FMA related 
issues
        CXXFLAGS="-I${T}/usr/include"
        LD_LIBRARY_PATH="${T}/usr/$(get_libdir)"
        OSL_DIR="${T}/usr/$(get_libdir)/cmake/OSL"
@@ -424,6 +293,10 @@ src_test() {
 
        cmake_src_test
 
+       einfo ""
+       einfo "testing render tests in isolation"
+       einfo ""
+
        CMAKE_SKIP_TESTS=(
                "^render-background$"
                "^render-mx-furnace-sheen$"
@@ -445,3 +318,15 @@ src_test() {
 
        cmake_src_test
 }
+
+src_install() {
+       cmake_src_install
+
+       if [[ -d "${ED}/usr/build-scripts" ]]; then
+               rm -rf "${ED}/usr/build-scripts" || die
+       fi
+
+       for batched_lib in "${ED}/usr/$(get_libdir)/lib_"*"_oslexec.so"; do
+               patchelf --set-soname "$(basename "${batched_lib}")" 
"${batched_lib}" || die
+       done
+}

Reply via email to