https://bugzilla.redhat.com/show_bug.cgi?id=2209759 --- Comment #14 from Tom Rix <trix@xxxxxxxxxx> --- with rocm-device-libs rpm installed My simple test is touch t.hip clang t.hip error: cannot find ROCm device library; provide its path via '--rocm-path' or '--rocm-device-lib-path', or pass '-nogpulib' to build without ROCm device library To work correctly is necessary to do clang --rocm-device-lib-path=/usr/lib64/amdgcn/bitcode t.hip >From this print out clang -print-rocm-search-dirs ROCm installation search path: /usr ROCm installation search path: /usr ROCm installation search path: /usr/lib64/clang/16 ROCm installation search path: /opt/rocm ROCm installation search path: /usr/local ROCm installation search path: /usr Because we could have different clangs installed, the best search path is /usr/lib64/clang/16 >From comments in clang/lib/Driver/ToolChains/AMDGPU.cpp, detectDeviceLibrary() // Find device libraries in <LLVM_DIR>/lib/clang/<ver>/lib/amdgcn/bitcode LibDevicePath = D.ResourceDir; llvm::sys::path::append(LibDevicePath, CLANG_INSTALL_LIBDIR_BASENAME, "amdgcn", "bitcode"); HasDeviceLibrary = CheckDeviceLib(LibDevicePath, true); if (HasDeviceLibrary) return; simply copying the directory there does not work, so i suspect this will need to with 2 changes. 1. rocm-device-libs follow what libomp does and use Requires: clang-resource-filesystem%{?isa} = %{version} to install amdgcn/bitcode into clang's resource dir lib/ 2. clang have a default to look there -- You are receiving this mail because: You are on the CC list for the bug. You are always notified about changes to this product and component https://bugzilla.redhat.com/show_bug.cgi?id=2209759 _______________________________________________ package-review mailing list -- package-review@xxxxxxxxxxxxxxxxxxxxxxx To unsubscribe send an email to package-review-leave@xxxxxxxxxxxxxxxxxxxxxxx Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/package-review@xxxxxxxxxxxxxxxxxxxxxxx Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue