generated from alpaca-core/tpl-ac-local-app
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathCMakeLists.txt
74 lines (60 loc) · 1.64 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
# Copyright (c) Alpaca Core
# SPDX-License-Identifier: MIT
#
cmake_minimum_required(VERSION 3.24 FATAL_ERROR)
project(acord
VERSION 0.1.0
DESCRIPTION "Alpaca Core local daemon"
LANGUAGES CXX
)
include(./get-ac-build.cmake)
CPMAddPackage(gh:iboB/[email protected])
list(APPEND CMAKE_MODULE_PATH
"${CMAKE_CURRENT_SOURCE_DIR}/cmake"
"${icm_SOURCE_DIR}"
)
include(init_ac_prj)
include(ac_build_prj_util)
include(icm_add_lib)
option(BUILD_SHARED_LIBS "Build shared libraries" ON) # not really needed, but it's a workaround for FindOpenSSL.cmake
option(ACORD_BUILD_TESTS "${PROJECT_NAME}: build tests" ${testsDefault})
option(ACORD_BUILD_EXAMPLES "${PROJECT_NAME}: build examples" ${examplesDefault})
mark_as_advanced(ACORD_BUILD_TESTS ACORD_BUILD_EXAMPLES)
macro(acord_add_test_subdir)
if(ACORD_BUILD_TESTS)
add_subdirectory(test)
endif()
endmacro()
#######################################
# packages
add_ac_local(0.1.18)
if(ACORD_BUILD_TESTS)
ac_dep(doctest-util)
endif()
#######################################
# plugins
if(NOT AC_BUILD_DEPLOY)
make_ac_local_plugin_available(
NAME ilib-foo
VERSION 0.1.2
GITHUB alpaca-core/ilib-foo
)
make_ac_local_plugin_available(
NAME ilib-llama.cpp
VERSION 0.1.0
GITHUB alpaca-core/ilib-llama.cpp
)
make_ac_local_plugin_available(
NAME ilib-sd.cpp
VERSION 0.1.0
GITHUB alpaca-core/ilib-sd.cpp
)
endif()
#######################################
# subdirs / targets
add_subdirectory(common)
add_subdirectory(server)
add_subdirectory(client)
if(ACORD_BUILD_EXAMPLES)
add_subdirectory(example)
endif()