summaryrefslogtreecommitdiff
path: root/dev-libs/rocr-runtime/rocr-runtime-5.7.1-r3.ebuild
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-06-27 07:59:40 +0100
committerV3n3RiX <venerix@koprulu.sector>2024-06-27 07:59:40 +0100
commitd2ed973482fdd800013658e83a61709b29e0a80f (patch)
tree57ea7666a57b5a05a4c8866e4915e90b4a6e7c94 /dev-libs/rocr-runtime/rocr-runtime-5.7.1-r3.ebuild
parent9f6a82a85d400d6ae7de04c43cee88dbc6bc4da0 (diff)
gentoo auto-resync : 27:06:2024 - 07:59:39
Diffstat (limited to 'dev-libs/rocr-runtime/rocr-runtime-5.7.1-r3.ebuild')
-rw-r--r--dev-libs/rocr-runtime/rocr-runtime-5.7.1-r3.ebuild60
1 files changed, 60 insertions, 0 deletions
diff --git a/dev-libs/rocr-runtime/rocr-runtime-5.7.1-r3.ebuild b/dev-libs/rocr-runtime/rocr-runtime-5.7.1-r3.ebuild
new file mode 100644
index 000000000000..57ea514d66ad
--- /dev/null
+++ b/dev-libs/rocr-runtime/rocr-runtime-5.7.1-r3.ebuild
@@ -0,0 +1,60 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+LLVM_MAX_SLOT=17
+
+inherit cmake flag-o-matic llvm
+
+if [[ ${PV} == *9999 ]] ; then
+ EGIT_REPO_URI="https://github.com/RadeonOpenCompute/ROCR-Runtime/"
+ inherit git-r3
+ S="${WORKDIR}/${P}/src"
+else
+ SRC_URI="https://github.com/RadeonOpenCompute/ROCR-Runtime/archive/rocm-${PV}.tar.gz -> ${P}.tar.gz"
+ S="${WORKDIR}/ROCR-Runtime-rocm-${PV}/src"
+ KEYWORDS="~amd64"
+fi
+
+DESCRIPTION="Radeon Open Compute Runtime"
+HOMEPAGE="https://github.com/RadeonOpenCompute/ROCR-Runtime"
+PATCHES=(
+ "${FILESDIR}/${PN}-4.3.0_no-aqlprofiler.patch"
+ "${FILESDIR}/${PN}-5.7.1-extend-isa-compatibility-check.patch"
+ "${FILESDIR}/${PN}-5.7.1-musl.patch"
+)
+
+LICENSE="MIT"
+SLOT="0/$(ver_cut 1-2)"
+IUSE="debug"
+
+COMMON_DEPEND="dev-libs/elfutils
+ x11-libs/libdrm"
+DEPEND="${COMMON_DEPEND}
+ >=dev-libs/roct-thunk-interface-${PV}
+ >=dev-libs/rocm-device-libs-${PV}
+ <=dev-libs/rocm-device-libs-6.0
+ sys-devel/clang:${LLVM_MAX_SLOT}=
+ sys-devel/lld:${LLVM_MAX_SLOT}="
+RDEPEND="${DEPEND}"
+BDEPEND="app-editors/vim-core"
+ # vim-core is needed for "xxd"
+
+src_prepare() {
+ # Gentoo installs "*.bc" to "/usr/lib" instead of a "[path]/bitcode" directory ...
+ sed -e "s:-O2:--rocm-path=${EPREFIX}/usr/lib/ -O2:" -i image/blit_src/CMakeLists.txt || die
+
+ cmake_src_prepare
+}
+
+src_configure() {
+ # -Werror=odr
+ # https://bugs.gentoo.org/856091
+ # https://github.com/ROCm/ROCR-Runtime/issues/182
+ filter-lto
+
+ use debug || append-cxxflags "-DNDEBUG"
+ local mycmakeargs=( -DINCLUDE_PATH_COMPATIBILITY=OFF )
+ cmake_src_configure
+}