From 2c3df160fb657b0bdd8a2f1b69172ad6728fad6b Mon Sep 17 00:00:00 2001 From: Andrei Betlen Date: Tue, 12 Sep 2023 18:29:18 -0400 Subject: [PATCH] Reorder --- CMakeLists.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 1677f83..3dbe74f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2,12 +2,11 @@ cmake_minimum_required(VERSION 3.4...3.22) project(llama_cpp) -option(BUILD_LLAMA_CPP "Build llama.cpp shared library and install alongside python package" ON) +option(LLAMA_BUILD "Build llama.cpp shared library and install alongside python package" ON) -if (BUILD_LLAMA_CPP) +if (LLAMA_BUILD) set(BUILD_SHARED_LIBS "On") - add_subdirectory(vendor/llama.cpp) if (APPLE) set(LLAMA_AVX OFF) set(LLAMA_AVX2 OFF) @@ -16,6 +15,7 @@ if (BUILD_LLAMA_CPP) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -march=native -mtune=native") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=native -mtune=native") endif() + add_subdirectory(vendor/llama.cpp) install( TARGETS llama LIBRARY DESTINATION ${SKBUILD_PLATLIB_DIR}/llama_cpp