From 42b25dacab6ddb90fc91ef6d479f3926692e30ae Mon Sep 17 00:00:00 2001 From: Pierrick HYMBERT Date: Sat, 16 Mar 2024 13:27:05 +0100 Subject: [PATCH] common: PR feedback, rename the definition to LLAMA_USE_CURL --- common/CMakeLists.txt | 2 +- common/common.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/common/CMakeLists.txt b/common/CMakeLists.txt index 79c3abdfe..9e85c2337 100644 --- a/common/CMakeLists.txt +++ b/common/CMakeLists.txt @@ -50,7 +50,7 @@ endif() # Check for curl find_package(CURL QUIET) if (CURL_FOUND) - add_definitions(-DHAVE_CURL) + add_definitions(-DLLAMA_USE_CURL) include_directories(${CURL_INCLUDE_DIRS}) link_libraries(${CURL_LIBRARIES}) else() diff --git a/common/common.cpp b/common/common.cpp index 4f955df30..1f57493df 100644 --- a/common/common.cpp +++ b/common/common.cpp @@ -16,7 +16,7 @@ #include #include #include -#ifdef HAVE_CURL +#ifdef LLAMA_USE_CURL #include #endif @@ -1387,7 +1387,7 @@ void llama_batch_add( batch.n_tokens++; } -#ifdef HAVE_CURL +#ifdef LLAMA_USE_CURL struct llama_model * llama_load_model_from_url(const char * model_url, const char * path_model, struct llama_model_params params) { // Initialize libcurl