public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Craig Andrews" <candrews@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/rocm-hostcall/, dev-libs/rocm-hostcall/files/
Date: Wed,  7 Aug 2019 17:38:53 +0000 (UTC)	[thread overview]
Message-ID: <1565199526.b8ca3b0862eb435d6259550372bb655908123d07.candrews@gentoo> (raw)

commit:     b8ca3b0862eb435d6259550372bb655908123d07
Author:     Craig Andrews <candrews <AT> gentoo <DOT> org>
AuthorDate: Wed Jul 31 15:22:09 2019 +0000
Commit:     Craig Andrews <candrews <AT> gentoo <DOT> org>
CommitDate: Wed Aug  7 17:38:46 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b8ca3b08

dev-libs/rocm-hostcall: Radeon Open Compute hostcall API

Package-Manager: Portage-2.3.69, Repoman-2.3.16
Signed-off-by: Craig Andrews <candrews <AT> gentoo.org>

 dev-libs/rocm-hostcall/Manifest                    |  1 +
 .../rocm-hostcall-2.7.0-install-correctly.patch    | 39 ++++++++++++++++++++++
 dev-libs/rocm-hostcall/metadata.xml                | 14 ++++++++
 dev-libs/rocm-hostcall/rocm-hostcall-2.7.0.ebuild  | 34 +++++++++++++++++++
 4 files changed, 88 insertions(+)

diff --git a/dev-libs/rocm-hostcall/Manifest b/dev-libs/rocm-hostcall/Manifest
new file mode 100644
index 00000000000..ca774830c73
--- /dev/null
+++ b/dev-libs/rocm-hostcall/Manifest
@@ -0,0 +1 @@
+DIST rocm-hostcall-2.7.0.tar.gz 1500771 BLAKE2B 275ad4cab34d554f8a131101eda474926f7270a44a0af9941d8f1233c29b44b3efb3ba83c6b541d501a3e2fc751c591c0f6a993563bbacf539b5bcd04b23963b SHA512 afb4a7318c2e137db6ac0502041ed53e63783ec1ab458962b1b16f0f2f28e09ce2ae70d048b858740eca8bf06328858400a68bed4e91d7cfc4b7714a66d85bc9

diff --git a/dev-libs/rocm-hostcall/files/rocm-hostcall-2.7.0-install-correctly.patch b/dev-libs/rocm-hostcall/files/rocm-hostcall-2.7.0-install-correctly.patch
new file mode 100644
index 00000000000..f419674886a
--- /dev/null
+++ b/dev-libs/rocm-hostcall/files/rocm-hostcall-2.7.0-install-correctly.patch
@@ -0,0 +1,39 @@
+https://github.com/RadeonOpenCompute/ROCm-CompilerSupport/pull/18
+
+From 345025de5c6c470e36505ff70978b168c05a1a71 Mon Sep 17 00:00:00 2001
+From: Craig Andrews <candrews@integralblue.com>
+Date: Wed, 31 Jul 2019 11:18:56 -0400
+Subject: [PATCH] Install to standard locations using GNUInstallDirs
+
+Some distributions require 64 bit libraries to be installed to lib64, for example.
+Using GNUInstallDirs ensures that files are installed to the expected locations.
+---
+ CMakeLists.txt | 8 +++++---
+ 1 file changed, 5 insertions(+), 3 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0f524e6..009bab7 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -5,6 +5,8 @@ if (NOT UNIX)
+     message(FATAL_ERROR "No Windows support due to lack of signals")
+ endif()
+ 
++include(GNUInstallDirs)
++
+ find_path(HSA_HEADER hsa/hsa.h PATHS /opt/rocm/include)
+ if (NOT EXISTS ${HSA_HEADER})
+     message(FATAL_ERROR "Cannot find HSA headers. Please check the CMAKE_PREFIX_PATH")
+@@ -34,9 +36,9 @@ target_compile_options(amd_hostcall
+ target_compile_definitions(amd_hostcall
+   PRIVATE "${AMD_HOSTCALL_PRIVATE_COMPILE_DEFINITIONS}")
+ 
+-set(INCLUDE_INSTALL_DIR include)
+-set(LIB_INSTALL_DIR lib)
+-set(SHARE_INSTALL_DIR share)
++set(INCLUDE_INSTALL_DIR ${CMAKE_INSTALL_INCLUDEDIR})
++set(LIB_INSTALL_DIR ${CMAKE_INSTALL_LIBDIR})
++set(SHARE_INSTALL_DIR ${CMAKE_INSTALL_DATADIR})
+ set(CONFIG_INSTALL_DIR ${LIB_INSTALL_DIR}/cmake/amd_hostcall)
+ 
+ install(TARGETS amd_hostcall

diff --git a/dev-libs/rocm-hostcall/metadata.xml b/dev-libs/rocm-hostcall/metadata.xml
new file mode 100644
index 00000000000..6b2718fcba0
--- /dev/null
+++ b/dev-libs/rocm-hostcall/metadata.xml
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+    <maintainer type="person">
+        <email>candrews@gentoo.org</email>
+        <name>Craig Andrews</name>
+    </maintainer>
+    <upstream>
+        <remote-id type="github">RadeonOpenCompute/ROCm-CompilerSupport</remote-id>
+    </upstream>
+    <longdescription lang="en">
+        Radeon Open Compute hostcall API
+    </longdescription>
+</pkgmetadata>

diff --git a/dev-libs/rocm-hostcall/rocm-hostcall-2.7.0.ebuild b/dev-libs/rocm-hostcall/rocm-hostcall-2.7.0.ebuild
new file mode 100644
index 00000000000..848a8f3a540
--- /dev/null
+++ b/dev-libs/rocm-hostcall/rocm-hostcall-2.7.0.ebuild
@@ -0,0 +1,34 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake-utils
+
+if [[ ${PV} == *9999 ]] ; then
+	EGIT_REPO_URI="https://github.com/RadeonOpenCompute/ROCm-CompilerSupport/"
+	inherit git-r3
+	S="${WORKDIR}/${P}/lib/hostcall"
+else
+	SRC_URI="https://github.com/RadeonOpenCompute/ROCm-CompilerSupport/archive/roc-${PV}.tar.gz -> ${P}.tar.gz"
+	S="${WORKDIR}/ROCm-CompilerSupport-roc-${PV}/lib/hostcall"
+	KEYWORDS="~amd64"
+fi
+PATCHES=(
+	"${FILESDIR}/${P}-install-correctly.patch"
+)
+
+DESCRIPTION="Radeon Open Compute hostcall API"
+HOMEPAGE="https://github.com/RadeonOpenCompute/ROCm-CompilerSupport"
+LICENSE="MIT"
+SLOT="0/$(ver_cut 1-2)"
+
+RDEPEND="dev-libs/rocr-runtime"
+DEPEND="${RDEPEND}"
+
+src_configure() {
+	local mycmakeargs=(
+		-DCMAKE_INSTALL_PREFIX="${EPREFIX}/usr/"
+	)
+	cmake-utils_src_configure
+}


                 reply	other threads:[~2019-08-07 17:39 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1565199526.b8ca3b0862eb435d6259550372bb655908123d07.candrews@gentoo \
    --to=candrews@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox