From f90a99cbbfff5dc0fab1dc2591f1c63aa354022c Mon Sep 17 00:00:00 2001 From: Adam Miller Date: Tue, 21 Jan 2025 17:28:55 -0600 Subject: [PATCH] fix cmake errors on fedora Signed-off-by: Adam Miller --- container-images/scripts/build_llama_and_whisper.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/container-images/scripts/build_llama_and_whisper.sh b/container-images/scripts/build_llama_and_whisper.sh index e90989be..842b06d5 100755 --- a/container-images/scripts/build_llama_and_whisper.sh +++ b/container-images/scripts/build_llama_and_whisper.sh @@ -37,7 +37,7 @@ dnf_install() { dnf install -y mesa-vulkan-drivers "${vulkan_rpms[@]}" "${rpm_list[@]}" elif [ "$containerfile" = "rocm" ]; then if [ "${ID}" = "fedora" ]; then - dnf install -y rocm-core-devel hipblas-devel rocblas-devel + dnf install -y rocm-core-devel hipblas-devel rocblas-devel rocm-hip-devel else dnf install -y rocm-dev hipblas-devel rocblas-devel fi @@ -72,6 +72,9 @@ configure_common_flags() { case "$containerfile" in rocm) common_flags+=("-DGGML_HIP=ON" "-DAMDGPU_TARGETS=${AMDGPU_TARGETS:-gfx1010,gfx1030,gfx1032,gfx1100,gfx1101,gfx1102}") + if [ "${ID}" = "fedora" ]; then + common_flags+=("-DCMAKE_HIP_COMPILER_ROCM_ROOT=/usr") + fi ;; cuda) common_flags+=("-DGGML_CUDA=ON" "-DCMAKE_EXE_LINKER_FLAGS=-Wl,--allow-shlib-undefined")