summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYiyangWu <xgreenlandforwyy@gmail.com>2022-02-20 16:32:43 +0800
committerBenda Xu <heroxbd@gentoo.org>2022-03-22 12:09:44 +0800
commit05304af68781496f9b8c4e8c2e1bda9e97d4406d (patch)
tree13233b47bf54788a1ee83cf3d308d89b0f095c06 /dev-libs/rocr-runtime
parentdev-libs/roct-thunk-interface: bump to 5.0.2 (diff)
downloadgentoo-05304af68781496f9b8c4e8c2e1bda9e97d4406d.tar.gz
gentoo-05304af68781496f9b8c4e8c2e1bda9e97d4406d.tar.bz2
gentoo-05304af68781496f9b8c4e8c2e1bda9e97d4406d.zip
dev-libs/rocr-runtime: bump version to 5.0.2
Package-Manager: Portage-3.0.30, Repoman-3.0.3 Signed-off-by: Yiyang Wu <xgreenlandforwyy@gmail.com> Signed-off-by: Benda Xu <heroxbd@gentoo.org>
Diffstat (limited to 'dev-libs/rocr-runtime')
-rw-r--r--dev-libs/rocr-runtime/Manifest1
-rw-r--r--dev-libs/rocr-runtime/files/rocr-runtime-5.0.1-cmake-install-paths.patch42
-rw-r--r--dev-libs/rocr-runtime/rocr-runtime-5.0.2.ebuild45
3 files changed, 88 insertions, 0 deletions
diff --git a/dev-libs/rocr-runtime/Manifest b/dev-libs/rocr-runtime/Manifest
index abe87a169710..b5911f37adcd 100644
--- a/dev-libs/rocr-runtime/Manifest
+++ b/dev-libs/rocr-runtime/Manifest
@@ -6,3 +6,4 @@ DIST rocr-runtime-4.1.0.tar.gz 698452 BLAKE2B fb1ca1219d2c59db4d8bff414f40eaf6e7
DIST rocr-runtime-4.2.0.tar.gz 701445 BLAKE2B 901c256bae823861813a7afdbd3e9f80b6f86cf2c7002815e04c762cef241a9f32274093067c97578e05fdf5c4e699287b7835d00917cb4997302c455e5d593a SHA512 44a798efd0121c7107f3f5df868eb83d0ff9aad1e11c01105d5852bef159c019db6d2aeebe02e8e187dc45a2542d72f145fb5390b27abf64e0b427e192772d6c
DIST rocr-runtime-4.3.0.tar.gz 709075 BLAKE2B 6856681bd3d56827e517f76838886f793f4d709562c2c7c4f480ef5786c5a5fac25654032b80d565ab5da241f76329d39ab3189daa4806b8cf1564d9f08a837d SHA512 749a8f84a302f7ed518f87688f68cc2a094eea2d104cddc25b3e5d98ddf6e534285750828ca654976054bbf986a61735e17ad211505557671627e44f6831dc0c
DIST rocr-runtime-4.5.2.tar.gz 717648 BLAKE2B f3acf32943b73b65f1272317bbd8928d1a05e9985ec6242f0480cfdb988052caef198900643fc42288af6acd5fbe2052f063b022219b2ef0d3fb843032de6c92 SHA512 69d7a3f7960ffca339d706a9356e0994851761a135e1b7e7b9b451bcff5782c119b99756432546e7f066f8b60b8717557340cf382f8a9beae6336d23d90ecae4
+DIST rocr-runtime-5.0.2.tar.gz 719840 BLAKE2B 3d0fd6df0a0ab1e180b4a6e61fdf6d796cf71ab7b259057a1942f70dfcbcf8cb5ee6ac563a4baefe3c608139eaf3d8433b5b58e871b45f43cb4d98d1889f6718 SHA512 0590975cab6463a39d78bad933f8e0d30cf23d100b58f5b1968f6d6bc4b88e3c6bca5c46783e321d4bfc9a685837385f90feb8e922523c002c1f4ea0c70bdf72
diff --git a/dev-libs/rocr-runtime/files/rocr-runtime-5.0.1-cmake-install-paths.patch b/dev-libs/rocr-runtime/files/rocr-runtime-5.0.1-cmake-install-paths.patch
new file mode 100644
index 000000000000..8715a15d8de1
--- /dev/null
+++ b/dev-libs/rocr-runtime/files/rocr-runtime-5.0.1-cmake-install-paths.patch
@@ -0,0 +1,42 @@
+Index: src/CMakeLists.txt
+===================================================================
+--- src.orig/CMakeLists.txt
++++ src/CMakeLists.txt
+@@ -286,35 +286,17 @@ if( NOT ${BUILD_SHARED_LIBS} )
+ install ( TARGETS ${CORE_RUNTIME_NAME} EXPORT ${CORE_RUNTIME_NAME}Targets )
+ endif()
+
+-## Create symlinks for legacy packaging and install
+-add_custom_target ( hsa_include_link ALL WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${CMAKE_COMMAND} -E create_symlink ../../include/hsa hsa_include_link )
+-if ( ${BUILD_SHARED_LIBS} )
+- add_custom_target ( hsa_lib_link ALL WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${CMAKE_COMMAND} -E create_symlink ../../lib/${CORE_RUNTIME_LIBRARY}.so ${CORE_RUNTIME_LIBRARY}-link.so )
+- add_custom_target ( hsa_lib_link2 ALL WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${CMAKE_COMMAND} -E create_symlink ../../lib/${CORE_RUNTIME_LIBRARY}.so.${VERSION_MAJOR} ${CORE_RUNTIME_LIBRARY}-link.so.${VERSION_MAJOR} )
+-endif()
+-
+ ## Set install information
+ # Installs binaries and exports the library usage data to ${HSAKMT_TARGET}Targets
+ # TODO: Fix me for flat directory layout. Should be ${CMAKE_INSTALL_LIBDIR}
+-install ( TARGETS ${CORE_RUNTIME_TARGET} EXPORT ${CORE_RUNTIME_NAME}Targets
+- ARCHIVE DESTINATION lib COMPONENT binary
+- LIBRARY DESTINATION lib COMPONENT binary )
++install ( TARGETS ${CORE_RUNTIME_TARGET} EXPORT ${CORE_RUNTIME_NAME}Targets LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} )
+
+ # Install license
+ install ( FILES ${CMAKE_CURRENT_SOURCE_DIR}/LICENSE.md DESTINATION ${CMAKE_INSTALL_DOCDIR} COMPONENT binary )
+
+ # Install public headers
+ # TODO: Fix me for flat directory layout. Should be ${CMAKE_INSTALL_INCLUDEDIR}
+-install ( DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/inc/ DESTINATION include/hsa COMPONENT dev )
+-
+-# Legacy symlink - not packaged (CPack is bugged until ~3.18, see https://gitlab.kitware.com/cmake/cmake/-/merge_requests/4637)
+-install ( FILES ${CMAKE_CURRENT_BINARY_DIR}/hsa_include_link DESTINATION hsa/include PERMISSIONS OWNER_WRITE OWNER_READ RENAME hsa )
+-
+-# Legacy symlinks.
+-if ( ${BUILD_SHARED_LIBS} )
+- install ( FILES ${CMAKE_CURRENT_BINARY_DIR}/${CORE_RUNTIME_LIBRARY}-link.so DESTINATION hsa/lib PERMISSIONS OWNER_WRITE OWNER_READ RENAME ${CORE_RUNTIME_LIBRARY}.so COMPONENT binary)
+- install ( FILES ${CMAKE_CURRENT_BINARY_DIR}/${CORE_RUNTIME_LIBRARY}-link.so.${VERSION_MAJOR} DESTINATION hsa/lib PERMISSIONS OWNER_WRITE OWNER_READ RENAME ${CORE_RUNTIME_LIBRARY}.so.${VERSION_MAJOR} COMPONENT binary)
+-endif ()
++install ( DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/inc/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/hsa )
+
+ ## Configure and install package config file
+ # Record our usage data for clients find_package calls.
diff --git a/dev-libs/rocr-runtime/rocr-runtime-5.0.2.ebuild b/dev-libs/rocr-runtime/rocr-runtime-5.0.2.ebuild
new file mode 100644
index 000000000000..c3e915ee947b
--- /dev/null
+++ b/dev-libs/rocr-runtime/rocr-runtime-5.0.2.ebuild
@@ -0,0 +1,45 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake
+
+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}-5.0.1-cmake-install-paths.patch"
+)
+
+LICENSE="MIT"
+SLOT="0/$(ver_cut 1-2)"
+
+COMMON_DEPEND="dev-libs/elfutils"
+RDEPEND="${COMMON_DEPEND}"
+DEPEND="${COMMON_DEPEND}
+ >=dev-libs/roct-thunk-interface-${PV}
+ >=dev-libs/rocm-device-libs-${PV}"
+BDEPEND="app-editors/vim-core"
+ # vim-core is needed for "xxd"
+
+CMAKE_BUILD_TYPE=Release
+
+src_prepare() {
+ # ... otherwise system llvm/clang is used ...
+ sed -e "/find_package(Clang REQUIRED HINTS /s:\${CMAKE_INSTALL_PREFIX}/llvm \${CMAKE_PREFIX_PATH}/llvm PATHS /opt/rocm/llvm:${EPREFIX}/usr/lib/llvm/roc:" -i image/blit_src/CMakeLists.txt || die
+
+ # Gentoo installs "*.bc" to "/usr/lib" instead of a "[path]/bitcode" directory ...
+ sed -e "s:/opt/rocm/amdgcn/bitcode:${EPREFIX}/usr/lib/amdgcn/bitcode:" -i image/blit_src/CMakeLists.txt || die
+
+ cmake_src_prepare
+}