* cmake : remove STATIC from impl libraries, allow BUILD_SHARED_LIBS control Remove explicit STATIC from all -impl libraries (server, cli, completion, bench, batched-bench, fit-params, quantize, perplexity) so BUILD_SHARED_LIBS controls shared vs static linkage. Add WINDOWS_EXPORT_ALL_SYMBOLS ON for proper DLL export on Windows. Assisted-by: llama.cpp:local pi * cmake : enable LLAMA_BUILD_APP by default Assisted-by: llama.cpp:local pi * ci : disable app in build-cmake-pkg.yml
22 lines
638 B
CMake
22 lines
638 B
CMake
# llama-quantize-impl: quantize logic, reusable by app
|
|
|
|
set(TARGET llama-quantize-impl)
|
|
|
|
add_library(${TARGET} quantize.cpp)
|
|
set_target_properties(${TARGET} PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS ON)
|
|
|
|
target_include_directories(${TARGET} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
|
|
target_link_libraries(${TARGET} PUBLIC llama-common llama ${CMAKE_THREAD_LIBS_INIT})
|
|
|
|
# llama-quantize executable
|
|
|
|
set(TARGET llama-quantize)
|
|
|
|
add_executable(${TARGET} main.cpp)
|
|
target_link_libraries(${TARGET} PRIVATE llama-quantize-impl)
|
|
target_compile_features(${TARGET} PRIVATE cxx_std_17)
|
|
|
|
if(LLAMA_TOOLS_INSTALL)
|
|
install(TARGETS ${TARGET} RUNTIME)
|
|
endif()
|