commit:     9d63fe4cd2eb5f65477e1d1d80f695207245cd62
Author:     Sv. Lockal <lockalsash <AT> gmail <DOT> com>
AuthorDate: Sun Aug 10 12:13:00 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat Sep  6 15:12:52 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9d63fe4c

sci-libs/miopen: fix dependencies

* app-arch/bzip2 is required
* dev-cpp/frugally-deep is only needed for AMD Instinct family
* move header-only libraries to DEPEND

Signed-off-by: Sv. Lockal <lockalsash <AT> gmail.com>
Part-of: https://github.com/gentoo/gentoo/pull/43406
Signed-off-by: Sam James <sam <AT> gentoo.org>

 ...{miopen-6.4.3.ebuild => miopen-6.4.3-r1.ebuild} | 39 ++++++++++++++++------
 1 file changed, 28 insertions(+), 11 deletions(-)

diff --git a/sci-libs/miopen/miopen-6.4.3.ebuild 
b/sci-libs/miopen/miopen-6.4.3-r1.ebuild
similarity index 80%
rename from sci-libs/miopen/miopen-6.4.3.ebuild
rename to sci-libs/miopen/miopen-6.4.3-r1.ebuild
index 2bc8c052a634..440bdc4a876d 100644
--- a/sci-libs/miopen/miopen-6.4.3.ebuild
+++ b/sci-libs/miopen/miopen-6.4.3-r1.ebuild
@@ -24,27 +24,32 @@ RESTRICT="test"
 
 RDEPEND="
        dev-util/hip:${SLOT}
-       >=dev-db/sqlite-3.17
+       dev-db/sqlite:3
+       app-arch/bzip2
        sci-libs/rocRAND:${SLOT}
-       >=dev-libs/boost-1.72
-       dev-cpp/nlohmann_json
-       dev-cpp/frugally-deep
+       dev-libs/boost:=
+       dev-libs/rocm-comgr:${SLOT}
 
        composable-kernel? ( sci-libs/composable-kernel:${SLOT} )
-       hipblaslt? (
-               sci-libs/hipBLAS:${SLOT}
-               sci-libs/hipBLASLt:${SLOT}
-       )
+       hipblaslt? ( sci-libs/hipBLASLt:${SLOT} )
        rocblas? ( sci-libs/rocBLAS:${SLOT} )
        roctracer? ( dev-util/roctracer:${SLOT} )
 "
 
-DEPEND="${RDEPEND}"
+DEPEND="
+       ${RDEPEND}
+       dev-cpp/nlohmann_json
+       >=dev-libs/half-1.12.0-r1
+       test? ( dev-cpp/gtest )
+
+       amdgpu_targets_gfx908? ( dev-cpp/frugally-deep )
+       amdgpu_targets_gfx940? ( dev-cpp/frugally-deep )
+       amdgpu_targets_gfx941? ( dev-cpp/frugally-deep )
+       amdgpu_targets_gfx942? ( dev-cpp/frugally-deep )
+"
 
 BDEPEND="
-       >=dev-libs/half-1.12.0-r1
        dev-build/rocm-cmake
-       test? ( dev-cpp/gtest )
 "
 
 PATCHES=(
@@ -90,6 +95,15 @@ src_configure() {
                CMAKE_BUILD_TYPE="Debug"
        fi
 
+       local use_ai_tuning=OFF
+       if use amdgpu_targets_gfx908 || use amdgpu_targets_gfx940 || use 
amdgpu_targets_gfx941 \
+       || use amdgpu_targets_gfx942; then
+               use_ai_tuning=ON
+       fi
+
+       # Too many warnings
+       append-cxxflags -Wno-switch-default
+
        local mycmakeargs=(
                -DCMAKE_SKIP_RPATH=ON
                -DGPU_TARGETS="$(get_amdgpu_flags)"
@@ -106,7 +120,10 @@ src_configure() {
                -DROCM_SYMLINK_LIBS=OFF
                -DMIOPEN_HIP_COMPILER="${ESYSROOT}/usr/bin/hipcc"
                -DMIOPEN_AMDGCN_ASSEMBLER="$(get_llvm_prefix)/bin/clang"
+               
-DMIOPEN_OFFLOADBUNDLER_BIN="$(get_llvm_prefix)/bin/clang-offload-bundler"
                -DHIP_OC_COMPILER="$(get_llvm_prefix)/bin/clang"
+               -DMIOPEN_ENABLE_AI_KERNEL_TUNING=${use_ai_tuning}
+               -DMIOPEN_ENABLE_AI_IMMED_MODE_FALLBACK=${use_ai_tuning}
        )
 
        if use test; then

Reply via email to