From eb1081d37ed2c220c1d8ccedc1d074b8528c5e65 Mon Sep 17 00:00:00 2001 From: Jared Van Bortel Date: Fri, 9 Feb 2024 22:00:14 -0500 Subject: [PATCH] cmake: fix LLAMA_DIR use before set Signed-off-by: Jared Van Bortel --- gpt4all-backend/llama.cpp.cmake | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/gpt4all-backend/llama.cpp.cmake b/gpt4all-backend/llama.cpp.cmake index f6bb2b6a..0bb79313 100644 --- a/gpt4all-backend/llama.cpp.cmake +++ b/gpt4all-backend/llama.cpp.cmake @@ -160,6 +160,7 @@ if (LLAMA_OPENBLAS) endif() if (LLAMA_KOMPUTE) + set(LLAMA_DIR ${CMAKE_CURRENT_SOURCE_DIR}/llama.cpp-mainline) if (NOT EXISTS "${LLAMA_DIR}/kompute/CMakeLists.txt") message(FATAL_ERROR "Kompute not found") endif() @@ -172,8 +173,6 @@ if (LLAMA_KOMPUTE) message(FATAL_ERROR "glslc not found") endif() - set(LLAMA_DIR ${CMAKE_CURRENT_SOURCE_DIR}/llama.cpp-mainline) - function(compile_shader) set(options) set(oneValueArgs)