How to install a HIP compiler on Rocky 8 Linux

I’m trying to get a HIP compiler on Rocky 8 Linux working using these steps:
https://github.com/Bforartists/Bforartists/wiki/Install-HIP-Compiler-Linux#rocky-8
I installed the rocm-hip-sdk package successfully,
but now every time I try to update packages I get this message:

Error: 
 Problem 1: package rocm-hip-runtime-devel-5.3.2.50302-96.el8.x86_64 requires rocm-device-libs = 1.0.0.50302, but none of the providers can be installed
  - cannot install both rocm-device-libs-5.2.3-1.el8.x86_64 and rocm-device-libs-1.0.0.50302-96.el8.x86_64
  - cannot install both rocm-device-libs-1.0.0.50302-96.el8.x86_64 and rocm-device-libs-5.2.3-1.el8.x86_64
  - cannot install the best update candidate for package rocm-hip-runtime-devel-5.3.2.50302-96.el8.x86_64
  - cannot install the best update candidate for package rocm-device-libs-1.0.0.50302-96.el8.x86_64
 Problem 2: package rocm-hip-runtime-5.3.2.50302-96.el8.x86_64 requires rocminfo = 1.0.0.50302, but none of the providers can be installed
  - cannot install both rocminfo-5.2.0-1.el8.x86_64 and rocminfo-1.0.0.50302-96.el8.x86_64
  - cannot install both rocminfo-1.0.0.50302-96.el8.x86_64 and rocminfo-5.2.0-1.el8.x86_64
  - cannot install the best update candidate for package rocminfo-1.0.0.50302-96.el8.x86_64
  - cannot install the best update candidate for package rocm-hip-runtime-5.3.2.50302-96.el8.x86_64
(try to add '--allowerasing' to command line to replace conflicting packages or '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)

should I just pin the version of these two packages so that it won’t complain,
or is there a better way to get a HIP compiler on Rocky 8?

Thanks in advance,
Best regards,
Iyad

CC: @bsavery

This is what we used on CentOS 7:

sudo sh -c 'echo "[ROCm]
name=ROCm
baseurl=https://repo.radeon.com/rocm/yum/5.3.2/main
enabled=1
gpgcheck=1
exclude=rock-dkms
gpgkey=https://repo.radeon.com/rocm/rocm.gpg.key" > /etc/yum.repos.d/rocm.repo'

sudo rpm --import https://repo.radeon.com/rocm/rocm.gpg.key

sudo yum install -y hip-devel rocm-llvm rocm-device-libs rocm-core

For the Rocky 8 command I can’t check right now. But basically you do not need all the kernel or runtime stuff to compile kernels, and so can leave out some packages.

2 Likes

Thanks a ton this helps :pray:

The instructions are now updated, dnf and yum do not complain anymore

Sadly only installing these packages still causes Blender to not find a HIP compiler

sudo yum install -y hip-devel rocm-llvm rocm-device-libs rocm-core

installing the rocm-hip-sdk and locking the version works for now

sudo yum --enablerepo=powertools install rocm-hip-sdk
sudo dnf install python3-dnf-plugin-versionlock
sudo dnf versionlock add rocm*