Created
September 15, 2018 06:01
-
-
Save HarlemSquirrel/ea923e07f492ed6cc451a60584ada630 to your computer and use it in GitHub Desktop.
ArchLinux PKGBUILD for rocm-opencl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Maintainer: Kevin McCormack <harlemsquirrel@gmail.com | |
pkgname=rocm-opencl | |
pkgver=1.2.0 | |
pkgverdate=2018090737 | |
pkgrel=2 | |
_debfile=rocm-opencl_${pkgver}-${pkgverdate}_amd64.deb | |
pkgdesc="ROCm Platform Runtime: Closed source opencl" | |
arch=('x86_64') | |
url="https://github.com/RadeonOpenCompute/ROCm" | |
license=('EULA') | |
groups=() | |
depends=() | |
makedepends=() | |
provides=("${pkgname%-git}") | |
conflicts=("${pkgname%-git}") | |
replaces=() | |
backup=() | |
options=() | |
source=("http://repo.radeon.com/rocm/apt/debian/pool/main/r/rocm-opencl/${_debfile}") | |
sha256sums=('9585eafbe3ad70646f7a2169074378558c36416b4ccfe13dac0baa95bf4698fd') | |
package() { | |
cd "$srcdir" | |
tar xJf data.tar.xz | |
cp -ax -R opt ${pkgdir}/ | |
# chmod -R 755 ${pkgdir}/opt | |
# https://github.com/RadeonOpenCompute/ROCm/issues/511#issuecomment-415614697 | |
mkdir -p ${pkgdir}/etc/ld.so.conf.d | |
echo /opt/rocm/opencl/lib/x86_64 > ${pkgdir}/etc/ld.so.conf.d/x86_64-rocm-opencl.conf && sudo ldconfig | |
mkdir -p ${pkgdir}/etc/OpenCL/vendors && (echo libamdocl64.so > ${pkgdir}/etc/OpenCL/vendors/amdocl64.icd) | |
# https://github.com/RadeonOpenCompute/ROCm#rocm-19-is-abi-compatible-with-kfd-in-upstream-linux-kernels | |
mkdir -p ${pkgdir}/etc/udev/rules.d/ | |
echo 'SUBSYSTEM=="kfd", KERNEL=="kfd", TAG+="uaccess", GROUP="video"' > ${pkgdir}/etc/udev/rules.d/70-kfd.rules | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment