kaeru 🐸


Stuff I'm working on ...

Latest note

by kaeru published Nov 21, 2021

ROCm 10 on Ubuntu Linux OpenCL and Shared Libraries

Latest ROCm release unifies everything under a single build and packing system TheRock, but there are still some loose ends on packaging side for Ubuntu to get OpenCL and shared libraries to work

by kaeru published Aug 28, 2026 , last modified Sep 08, 2026
ROCm 10 on Ubuntu Linux OpenCL and Shared Libraries
Darktable with OpenCL AMD GPU accelerated image processing

AMD's version release of ROCm was confusing with production at 7.2 and pre-release at 7.14, but they decided to jump a major version numbers straight to 10. You can read the media release on AMD's site, with the buzzword marketing title, "ROCm 10.0: A Decade of Open Compute, Built for the Age of Agentic AI".

A single test, build and release system for all the different parts, should hopefully speed up development, especially for all the rough edges before it hopefully lands in future upstream Ubuntu/Debian repositories.

The install is mostly straightforward, with some caveats for OpenCL ICD drivers and linked libraries.

rocm directory in /opt/rocm now looks like this with core-<version> instead of rocm-<version>. If you have older versions, they will also be here. I'm not a fan of mixing versions in base, as it increases chances of problems due to mismatched and dangling files. I would use LXD or docker containers to that instead if I need to use specific versions of ROCm.

amdgcn  bin  core  core-10  core-10.0  include  lib  libexec  llvm  share

Installation

Installation for your different devices are at the AMD ROCm latest page. There is now clear support for Ryzen Max AI or "Strix Halo" also. For consumer GPU and APU, you probably want compute+graphics, which will give you an installation and helper script (amdgpu-install) to download various dependencies based on use case. 

The recommended rocm,graphics use cases should be enough for your graphics, gaming and multimedia needs. If you need to compile from source software like llama.cpp then you should also add rocmdev,hiplibsdk

Missing OpenCL ICD and Shared Libraries

Unlike previous stable packaged versions of ROCm 7.1 in Ubuntu base or ROCm 7.2, installing amdrocm-opencl won't lead to an immediately working OpenCL. clinfo will return no devices.

You'll need copy or link the OpenCL ICD and linked libary ldconfig conf file in /etc/ first. Annoyingly this isn't documented or mentioned in any of the installation steps.

  1. Copy or link /opt/rocm/core/etc/OpenCL/vendors/amdocl64.icd to /etc/OpenCL/vendors/amdocl64.icd
  2. Copy or link /opt/rocm/core/etc/ld.so.conf.d/10-rocm-opencl.conf to /etc/ld.so.conf.d then run ldconfig

And your OpenCL applications should be working! This should be fixed in next minor release of ROCm 10, you can track the issue for the fix here.

If you're still getting issues, you might need to edit 10-rocm-opencl.conf to point to the full path /opt/rocm/lib/opencl

AMD Advanced Media Framework (AMF) SDK

If you want hardware accelerated encoding and decoding for h264, h265 and av1, you'll still have to install it separately. It's listed as a use case option for amdgpu-installer but seems to be missing, you'll still need to install this with a separate installation script for now. I had a previous post on getting AMF to work with FFMpeg.

Davinci Resolve

Update: In original post, I mentioned there were some regressions, but this is incorrect. A clean install and making sure the right OpenCL driver library is loaded is key.

On the application side, Davinci Resolve is the pickiest application. If anything breaks related to OpenCL, it's probably DaVinci, from thumbnail previews not working or the AI features failing with errors like "GPU Error :1" 

Can confirm it's working with latest DaVinci Resolve Studio 21.0.4 and ROCm 10. 

Troubleshooting checklist:

  • Make sure you have a clean environment. Find and remove any libraries packages from the built-in or previous versions of ROCm first.
    • /etc/OpenCL/vendors for any old / stray .icd files
    • /etc/ld.so.conf.d for older or custom rocm-opencl.conf files pointing to old paths 
  • If using the official amdgpu-install debian package and script, make sure there is no old legacy rocm.source or related repo.radeon.amd.com apt source files in /etc/apt/sources.list.d/ Before running it. Even bak files. The script will silently fail and not install the required repository source files.
  • Run ldconfig -p and look for libamdocl64 entries and check that they are pointing to the right rocm paths 
  • Run ls -l /etc/alternatives | grep rocm to check if the /opt/rocm paths are pointing to the core-10 and not other versions of rocm