From 6337b737c37c63b6ef9ddd80232f01a1f577325e Mon Sep 17 00:00:00 2001 From: kennethge <57784063+kenneth-ge@users.noreply.github.com> Date: Mon, 4 Mar 2024 14:17:48 -0500 Subject: [PATCH] cmake : add library versioning (#1352) Co-authored-by: Georgi Gerganov --- CMakeLists.txt | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 7d95d3d0e86..dce71ff6e47 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,6 +1,7 @@ cmake_minimum_required (VERSION 3.5) project(whisper.cpp VERSION 1.5.4) +set(SOVERSION 1) # Add path to modules list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake/") @@ -542,6 +543,12 @@ add_library(${TARGET} whisper.cpp ) +# Set the version numbers +set_target_properties(whisper PROPERTIES + VERSION ${PROJECT_VERSION} + SOVERSION ${SOVERSION} +) + include(DefaultTargetOptions) target_include_directories(${TARGET} PUBLIC