mirror of
https://github.com/ravenscroftj/turbopilot.git
synced 2024-10-01 01:06:01 -04:00
fix build?
This commit is contained in:
parent
22f2993db4
commit
f69a8f65d4
@ -1,7 +1,14 @@
|
||||
cmake_minimum_required (VERSION 3.0)
|
||||
project(turbopilot VERSION 0.1.0)
|
||||
set(CMAKE_CXX_STANDARD 11)
|
||||
set(CMAKE_CXX_STANDARD_REQUIRED true)
|
||||
set(CMAKE_C_STANDARD 11)
|
||||
set(CMAKE_C_STANDARD_REQUIRED true)
|
||||
set(THREADS_PREFER_PTHREAD_FLAG ON)
|
||||
find_package(Threads REQUIRED)
|
||||
|
||||
option(BUILD_SHARED_LIBS "Build using shared libraries" OFF)
|
||||
|
||||
# option(BUILD_SHARED_LIBS "Build using shared libraries" OFF)
|
||||
|
||||
|
||||
set(CMAKE_EXPORT_COMPILE_COMMANDS "on")
|
||||
@ -31,17 +38,22 @@ endif()
|
||||
|
||||
|
||||
|
||||
if (GGML_STATIC)
|
||||
SET(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
|
||||
SET(BUILD_SHARED_LIBS OFF)
|
||||
SET(CMAKE_EXE_LINKER_FLAGS "-static")
|
||||
endif()
|
||||
|
||||
|
||||
add_subdirectory(extern/ggml)
|
||||
add_subdirectory(extern/argparse)
|
||||
add_subdirectory(extern/spdlog)
|
||||
|
||||
if (GGML_STATIC)
|
||||
SET(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
|
||||
SET(BUILD_SHARED_LIBS OFF)
|
||||
SET(CMAKE_EXE_LINKER_FLAGS "-static")
|
||||
|
||||
# if(GGML_OPENBLAS)
|
||||
# set(BLA_STATIC ON)
|
||||
# endif()
|
||||
endif()
|
||||
|
||||
|
||||
add_subdirectory(src)
|
||||
|
||||
|
@ -17,8 +17,8 @@ add_executable(${TURBOPILOT_TARGET}
|
||||
../include/turbopilot/starcoder.hpp
|
||||
)
|
||||
|
||||
set(THREADS_PREFER_PTHREAD_FLAG TRUE)
|
||||
find_package(Threads REQUIRED)
|
||||
#set(THREADS_PREFER_PTHREAD_FLAG TRUE)
|
||||
#find_package(Threads REQUIRED)
|
||||
|
||||
|
||||
target_include_directories(${TURBOPILOT_TARGET} PRIVATE
|
||||
@ -27,9 +27,6 @@ target_include_directories(${TURBOPILOT_TARGET} PRIVATE
|
||||
../extern/crow/include
|
||||
)
|
||||
|
||||
#target_compile_features(${TURBOPILOT_TARGET} PRIVATE cxx_std_11)
|
||||
|
||||
|
||||
target_link_libraries(${TURBOPILOT_TARGET} PRIVATE ggml argparse Threads::Threads)
|
||||
|
||||
|
||||
#target_link_libraries(${TURBOPILOT_TARGET} PRIVATE spdlog::spdlog_header_only)
|
||||
target_link_libraries(${TURBOPILOT_TARGET} PRIVATE ggml argparse)
|
Loading…
Reference in New Issue
Block a user