commit: 887d4459a5c668b2a3639259e6262bf6639556ef
Author: Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
AuthorDate: Wed May 25 05:47:00 2022 +0000
Commit: Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
CommitDate: Wed May 25 12:17:52 2022 +0000
URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=887d4459
sci-libs/magma: allow multiple gpu implementations
Signed-off-by: Alessandro Barbieri <lssndrbarbieri <AT> gmail.com>
sci-libs/magma/magma-2.6.2.ebuild | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/sci-libs/magma/magma-2.6.2.ebuild
b/sci-libs/magma/magma-2.6.2.ebuild
index 95bcf8ca4..a8c48659f 100644
--- a/sci-libs/magma/magma-2.6.2.ebuild
+++ b/sci-libs/magma/magma-2.6.2.ebuild
@@ -30,6 +30,7 @@ IUSE_AMDGPU="
"
IUSE="doc openblas test ${IUSE_AMDGPU}"
+# TODO: do not enforce openblas
RDEPEND="
openblas? ( sci-libs/openblas )
!openblas? (
@@ -47,7 +48,7 @@ BDEPEND="
doc? ( >=app-doc/doxygen-1.8.14-r1[dot] )
"
-REQUIRED_USE="^^ ( ${IUSE_AMDGPU/+/} )"
+REQUIRED_USE="|| ( ${IUSE_AMDGPU/+/} )"
RESTRICT="!test? ( test )"
pkg_setup() {
@@ -83,12 +84,16 @@ src_configure() {
# other options: Intel10_64lp, Intel10_64lp_seq, Intel10_64ilp,
Intel10_64ilp_seq, Intel10_32, FLAME, ACML, Apple, NAS
local blasvendor="Generic"
use openblas && blasvendor="OpenBLAS"
+
+ local gpu=""
for u in ${IUSE_AMDGPU} ; do
if use ${u} ; then
- gpu="${u/amdgpu_/}"
- break
+ gpu="${gpu},${u/amdgpu_/}"
fi
done
+ #remove first character (,)
+ gpu="${gpu:1}"
+
local mycmakeargs=(
-DBUILD_SHARED_LIBS=ON
-DCMAKE_CXX_COMPILER=hipcc