1 |
commit: 57f6db34f6f6e016bda0670ccf09fb9684aebfd3 |
2 |
Author: Marek Szuba <marecki <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat May 25 21:09:57 2019 +0000 |
4 |
Commit: Marek Szuba <marecki <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat May 25 21:12:24 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=57f6db34 |
7 |
|
8 |
dev-libs/amdgpu-pro-opencl: bump to 19.10.785425 |
9 |
|
10 |
The customised libdrm, which was not necessary with 18.20, is back. |
11 |
Everything seems to work fine on my system, LuxMark consistently |
12 |
benchmarks 5-10 percent slower than with 18.20 though. |
13 |
|
14 |
Closes: https://bugs.gentoo.org/669326 |
15 |
Closes: https://bugs.gentoo.org/669562 |
16 |
|
17 |
Signed-off-by: Marek Szuba <marecki <AT> gentoo.org> |
18 |
Package-Manager: Portage-2.3.66, Repoman-2.3.11 |
19 |
|
20 |
dev-libs/amdgpu-pro-opencl/Manifest | 1 + |
21 |
.../amdgpu-pro-opencl-19.10.785425.ebuild | 99 ++++++++++++++++++++++ |
22 |
2 files changed, 100 insertions(+) |
23 |
|
24 |
diff --git a/dev-libs/amdgpu-pro-opencl/Manifest b/dev-libs/amdgpu-pro-opencl/Manifest |
25 |
index 3fea723843e..f121307d8f2 100644 |
26 |
--- a/dev-libs/amdgpu-pro-opencl/Manifest |
27 |
+++ b/dev-libs/amdgpu-pro-opencl/Manifest |
28 |
@@ -1 +1,2 @@ |
29 |
DIST amdgpu-pro-18.20-684755-ubuntu-16.04.tar.xz 229474380 BLAKE2B f589aad71f093b74e37de40ac7c45ebbbeff93609b2fff1baaba711347a4641ef17acdcbe69d371372510a48bd48262cf6269c1f4d05e264023d52a425a423f2 SHA512 240e701acfde4ebe665cf69c8bd3710d036f450822aeb7ee2a21caab289af44167afda1d3b8d0dbe2c46c4e63d9b6fb5e96778311f342c26f334dc7beb4a2d5b |
30 |
+DIST amdgpu-pro-19.10-785425-ubuntu-18.04.tar.xz 243520380 BLAKE2B 8c775feaff685b18b6df2f6f17667dbadb3da89f58c823f5470113342b585ecb436fbacef6ba26b35fe05bac53530cfe334d79d933afee303651e1375654da85 SHA512 d9c214134bf220c2ab4a306f5d83ce5718adc1f3e93165c724e70b99b4b5bcd8e703299ed70fe79f1d2db5f4f69cae2e1036b5a6238696346710c88f7fa6b3c6 |
31 |
|
32 |
diff --git a/dev-libs/amdgpu-pro-opencl/amdgpu-pro-opencl-19.10.785425.ebuild b/dev-libs/amdgpu-pro-opencl/amdgpu-pro-opencl-19.10.785425.ebuild |
33 |
new file mode 100644 |
34 |
index 00000000000..f86cc108a69 |
35 |
--- /dev/null |
36 |
+++ b/dev-libs/amdgpu-pro-opencl/amdgpu-pro-opencl-19.10.785425.ebuild |
37 |
@@ -0,0 +1,99 @@ |
38 |
+# Copyright 1999-2019 Gentoo Authors |
39 |
+# Distributed under the terms of the GNU General Public License v2 |
40 |
+ |
41 |
+EAPI=7 |
42 |
+ |
43 |
+MULTILIB_COMPAT=( abi_x86_{32,64} ) |
44 |
+ |
45 |
+inherit unpacker multilib-minimal |
46 |
+ |
47 |
+SUPER_PN='amdgpu-pro' |
48 |
+MY_PV=$(ver_rs 2 '-') |
49 |
+ |
50 |
+DESCRIPTION="Proprietary OpenCL implementation for AMD GPUs" |
51 |
+HOMEPAGE="https://www.amd.com/en/support/kb/release-notes/rn-rad-lin-19-10-unified" |
52 |
+SRC_URI="${SUPER_PN}-${MY_PV}-ubuntu-18.04.tar.xz" |
53 |
+ |
54 |
+LICENSE="AMD-GPU-PRO-EULA" |
55 |
+SLOT="0" |
56 |
+KEYWORDS="~amd64 ~x86" |
57 |
+ |
58 |
+RESTRICT="mirror fetch strip" |
59 |
+ |
60 |
+BDEPEND="dev-util/patchelf" |
61 |
+COMMON="app-eselect/eselect-opencl |
62 |
+ dev-libs/ocl-icd" |
63 |
+DEPEND="${COMMON}" |
64 |
+RDEPEND="${COMMON}" |
65 |
+ |
66 |
+QA_PREBUILT="/opt/amdgpu/lib*/*" |
67 |
+ |
68 |
+S="${WORKDIR}/${SUPER_PN}-${MY_PV}-ubuntu-18.04" |
69 |
+ |
70 |
+pkg_nofetch() { |
71 |
+ local pkgver=$(ver_cut 1-2) |
72 |
+ einfo "Please download Radeon Software for Linux version ${pkgver} for Ubuntu 18.04 from" |
73 |
+ einfo " ${HOMEPAGE}" |
74 |
+ einfo "The archive should then be placed into your distfiles directory." |
75 |
+} |
76 |
+ |
77 |
+src_unpack() { |
78 |
+ default |
79 |
+ |
80 |
+ local ids_ver="1.0.0" |
81 |
+ local patchlevel=$(ver_cut 3) |
82 |
+ cd "${S}" || die |
83 |
+ unpack_deb "${S}/libdrm-amdgpu-common_${ids_ver}-${patchlevel}_all.deb" |
84 |
+ multilib_parallel_foreach_abi multilib_src_unpack |
85 |
+} |
86 |
+ |
87 |
+multilib_src_unpack() { |
88 |
+ local libdrm_ver="2.4.97" |
89 |
+ local patchlevel=$(ver_cut 3) |
90 |
+ local deb_abi |
91 |
+ [[ ${ABI} == x86 ]] && deb_abi=i386 |
92 |
+ |
93 |
+ mkdir -p "${BUILD_DIR}" || die |
94 |
+ pushd "${BUILD_DIR}" >/dev/null || die |
95 |
+ unpack_deb "${S}/opencl-orca-amdgpu-pro-icd_${MY_PV}_${deb_abi:-${ABI}}.deb" |
96 |
+ unpack_deb "${S}/libdrm-amdgpu-amdgpu1_${libdrm_ver}-${patchlevel}_${deb_abi:-${ABI}}.deb" |
97 |
+ popd >/dev/null || die |
98 |
+} |
99 |
+ |
100 |
+multilib_src_install() { |
101 |
+ local dir_abi short_abi |
102 |
+ [[ ${ABI} == x86 ]] && dir_abi=i386-linux-gnu && short_abi=32 |
103 |
+ [[ ${ABI} == amd64 ]] && dir_abi=x86_64-linux-gnu && short_abi=64 |
104 |
+ |
105 |
+ into "/opt/amdgpu" |
106 |
+ patchelf --set-rpath '$ORIGIN' "opt/${SUPER_PN}/lib/${dir_abi}"/libamdocl-orca${short_abi}.so || die "Failed to fix library rpath" |
107 |
+ dolib.so "opt/${SUPER_PN}/lib/${dir_abi}"/* |
108 |
+ dolib.so "opt/amdgpu/lib/${dir_abi}"/* |
109 |
+ |
110 |
+ insinto /etc/OpenCL/vendors |
111 |
+ echo "/opt/amdgpu/$(get_libdir)/libamdocl-orca${short_abi}.so" \ |
112 |
+ > "${T}/${SUPER_PN}-${ABI}.icd" || die "Failed to generate ICD file for ABI ${ABI}" |
113 |
+ doins "${T}/${SUPER_PN}-${ABI}.icd" |
114 |
+} |
115 |
+ |
116 |
+# FIXME: is this right? |
117 |
+multilib_src_install_all() { |
118 |
+ ewarn "FOO $PWD" |
119 |
+ ewarn `ls` |
120 |
+ insinto "/opt/amdgpu" |
121 |
+ doins -r opt/amdgpu/share |
122 |
+} |
123 |
+ |
124 |
+pkg_postinst() { |
125 |
+ if [[ -z "${REPLACING_VERSIONS}" ]]; then |
126 |
+ ewarn "Please note that using proprietary OpenCL libraries together with the" |
127 |
+ ewarn "Open Source amdgpu stack is not officially supported by AMD. Do not ask them" |
128 |
+ ewarn "for support in case of problems with this package." |
129 |
+ ewarn "" |
130 |
+ ewarn "Furthermore, if you have the whole AMDGPU-Pro stack installed this package" |
131 |
+ ewarn "will almost certainly conflict with it. This might change once AMDGPU-Pro" |
132 |
+ ewarn "has become officially supported by Gentoo." |
133 |
+ fi |
134 |
+ |
135 |
+ "${ROOT}"/usr/bin/eselect opencl set --use-old ocl-icd |
136 |
+} |