mirror of
https://github.com/LostRuins/koboldcpp.git
synced 2026-10-03 03:25:40 +00:00
cmake : fix build when GGML_CPU=OFF and GGML_CUDA=ON (#29026)
* fix: build fails when GGML_CPU=OFF and GGML_CUDA=ON * fix: eol in examples/convert-llama2c-to-ggml/CMakeLists.txt file
This commit is contained in:
parent
bb11ebb682
commit
8ed1a55efc
3 changed files with 9 additions and 7 deletions
|
|
@ -1,5 +1,7 @@
|
||||||
set(TARGET llama-convert-llama2c-to-ggml)
|
if (GGML_CPU)
|
||||||
add_executable(${TARGET} convert-llama2c-to-ggml.cpp)
|
set(TARGET llama-convert-llama2c-to-ggml)
|
||||||
install(TARGETS ${TARGET} RUNTIME)
|
add_executable(${TARGET} convert-llama2c-to-ggml.cpp)
|
||||||
target_link_libraries(${TARGET} PRIVATE llama-common llama ${CMAKE_THREAD_LIBS_INIT})
|
install(TARGETS ${TARGET} RUNTIME)
|
||||||
target_compile_features(${TARGET} PRIVATE cxx_std_17)
|
target_link_libraries(${TARGET} PRIVATE llama-common llama ${CMAKE_THREAD_LIBS_INIT})
|
||||||
|
target_compile_features(${TARGET} PRIVATE cxx_std_17)
|
||||||
|
endif()
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ include_directories(${CMAKE_CURRENT_SOURCE_DIR})
|
||||||
|
|
||||||
if (EMSCRIPTEN)
|
if (EMSCRIPTEN)
|
||||||
else()
|
else()
|
||||||
if (NOT GGML_BACKEND_DL)
|
if (NOT GGML_BACKEND_DL AND GGML_CPU)
|
||||||
add_subdirectory(vdot)
|
add_subdirectory(vdot)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
|
||||||
|
|
@ -322,7 +322,7 @@ if (APPLE)
|
||||||
llama_build(test-rset-release.cpp)
|
llama_build(test-rset-release.cpp)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (NOT GGML_BACKEND_DL)
|
if (NOT GGML_BACKEND_DL AND GGML_CPU)
|
||||||
# these tests use the backends directly and cannot be built with dynamic loading
|
# these tests use the backends directly and cannot be built with dynamic loading
|
||||||
llama_build_and_test(test-barrier.cpp)
|
llama_build_and_test(test-barrier.cpp)
|
||||||
llama_build_and_test(test-quantize-fns.cpp)
|
llama_build_and_test(test-quantize-fns.cpp)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue