FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
llama-cpp-python/CMakeLists.txt at main · bigdatasciencegroup/llama-cpp-python · GitHub
Uh oh!
There was an error while loading.
Please reload this page
.
bigdatasciencegroup
/
llama-cpp-python
Public
forked from
abetlen/llama-cpp-python
Notifications
You must be signed in to change notification settings
Fork
0
Star
0
Code
Pull requests
0
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
llama-cpp-python
/
CMakeLists.txt
Copy path
More file actions
More file actions
Latest commit
History
History
History
45 lines (41 loc) · 1.82 KB
Breadcrumbs
llama-cpp-python
/
CMakeLists.txt
Copy path
File metadata and controls
45 lines (41 loc) · 1.82 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
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
cmake_minimum_required
(
VERSION
3.21
)
project
(llama_cpp)
option
(
LLAMA_BUILD
"Build llama.cpp shared library and install alongside python package"
ON
)
if
(LLAMA_BUILD)
set
(
BUILD_SHARED_LIBS
"On"
)
if
(
APPLE
AND
NOT
CMAKE_SYSTEM_PROCESSOR
MATCHES
"arm64"
)
#
Need to disable these llama.cpp flags on Apple x86_64,
#
otherwise users may encounter invalid instruction errors
set
(LLAMA_AVX
"Off"
CACHE
BOOL
"llama: enable AVX"
FORCE
)
set
(LLAMA_AVX2
"Off"
CACHE
BOOL
"llama: enable AVX2"
FORCE
)
set
(LLAMA_FMA
"Off"
CACHE
BOOL
"llama: enable FMA"
FORCE
)
set
(LLAMA_F16C
"Off"
CACHE
BOOL
"llama: enable F16C"
FORCE
)
endif
()
add_subdirectory
(
vendor/llama.cpp
)
install
(
TARGETS
llama
LIBRARY
DESTINATION
${SKBUILD_PLATLIB_DIR}
/llama_cpp
RUNTIME
DESTINATION
${SKBUILD_PLATLIB_DIR}
/llama_cpp
ARCHIVE
DESTINATION
${SKBUILD_PLATLIB_DIR}
/llama_cpp
FRAMEWORK
DESTINATION
${SKBUILD_PLATLIB_DIR}
/llama_cpp
RESOURCE
DESTINATION
${SKBUILD_PLATLIB_DIR}
/llama_cpp
)
#
Temporary fix for https://github.com/scikit-build/scikit-build-core/issues/374
install
(
TARGETS
llama
LIBRARY
DESTINATION
${
CMAKE_CURRENT_SOURCE_DIR
}
/llama_cpp
RUNTIME
DESTINATION
${
CMAKE_CURRENT_SOURCE_DIR
}
/llama_cpp
ARCHIVE
DESTINATION
${
CMAKE_CURRENT_SOURCE_DIR
}
/llama_cpp
FRAMEWORK
DESTINATION
${
CMAKE_CURRENT_SOURCE_DIR
}
/llama_cpp
RESOURCE
DESTINATION
${
CMAKE_CURRENT_SOURCE_DIR
}
/llama_cpp
)
#
Workaround for Windows + CUDA https://github.com/abetlen/llama-cpp-python/issues/563
install
(
FILES
$<
TARGET_RUNTIME_DLLS
:
llama
>
DESTINATION
${SKBUILD_PLATLIB_DIR}
/llama_cpp
)
install
(
FILES
$<
TARGET_RUNTIME_DLLS
:
llama
>
DESTINATION
${
CMAKE_CURRENT_SOURCE_DIR
}
/llama_cpp
)
endif
()
Back
|
FazBrowse Home
|
New Git URL