From 738a8d12eb0ba09a1f7bab650f267d96c44b883a Mon Sep 17 00:00:00 2001 From: Daniel Hiltgen Date: Sun, 24 Dec 2023 14:12:21 -0800 Subject: [PATCH] Rename the ollama cmakefile --- llm/llama.cpp/{ollama.txt => CMakeLists.txt} | 0 llm/llama.cpp/gen_common.sh | 4 ++-- llm/llama.cpp/gen_windows.ps1 | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) rename llm/llama.cpp/{ollama.txt => CMakeLists.txt} (100%) diff --git a/llm/llama.cpp/ollama.txt b/llm/llama.cpp/CMakeLists.txt similarity index 100% rename from llm/llama.cpp/ollama.txt rename to llm/llama.cpp/CMakeLists.txt diff --git a/llm/llama.cpp/gen_common.sh b/llm/llama.cpp/gen_common.sh index 25b98f2f..dfdd69cc 100644 --- a/llm/llama.cpp/gen_common.sh +++ b/llm/llama.cpp/gen_common.sh @@ -26,8 +26,8 @@ git_module_setup() { apply_patches() { # Wire up our CMakefile - if ! grep ollama.txt gguf/examples/server/CMakeLists.txt; then - echo 'include (../../../ollama.txt)' >>gguf/examples/server/CMakeLists.txt + if ! grep ollama gguf/examples/server/CMakeLists.txt; then + echo 'include (../../../CMakeLists.txt) # ollama' >>gguf/examples/server/CMakeLists.txt fi # Avoid duplicate main symbols when we link into the cgo binary sed -e 's/int main(/int __main(/g' <./gguf/examples/server/server.cpp >./gguf/examples/server/server.cpp.tmp && diff --git a/llm/llama.cpp/gen_windows.ps1 b/llm/llama.cpp/gen_windows.ps1 index 3f85cbb2..879e7cd2 100644 --- a/llm/llama.cpp/gen_windows.ps1 +++ b/llm/llama.cpp/gen_windows.ps1 @@ -25,8 +25,8 @@ function git_module_setup { function apply_patches { # Wire up our CMakefile - if (!(Select-String -Path "gguf/examples/server/CMakeLists.txt" -Pattern 'ollama.txt')) { - Add-Content -Path "gguf/examples/server/CMakeLists.txt" -Value 'include (../../../ollama.txt)' + if (!(Select-String -Path "gguf/examples/server/CMakeLists.txt" -Pattern 'ollama')) { + Add-Content -Path "gguf/examples/server/CMakeLists.txt" -Value 'include (../../../CMakeLists.txt) # ollama' } # Avoid duplicate main symbols when we link into the cgo binary $content = Get-Content -Path "./gguf/examples/server/server.cpp"