The problem
This is a request to add an SOVERSION to the shared library libmatplot that may only be incremented to indicate breakage or interface changes. According to TLDP,
Every shared library has a special name called the "soname''. The soname has the prefix "lib'', the name of the library, the phrase ".so'', followed by a period and a version number that is incremented whenever the interface changes
The solution I'd like
Ideally the soversion will be the major version, i.e. 1 for matplot++ 1.2.x. This patch does it:
Index: matplotplusplus-1.2.1/source/matplot/CMakeLists.txt
===================================================================
--- matplotplusplus-1.2.1.orig/source/matplot/CMakeLists.txt
+++ matplotplusplus-1.2.1/source/matplot/CMakeLists.txt
@@ -98,7 +98,7 @@ target_include_directories(matplot
PUBLIC $<BUILD_INTERFACE:${MATPLOT_ROOT_DIR}/source>
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>)
-set_target_properties(matplot PROPERTIES VERSION ${PROJECT_VERSION})
+set_target_properties(matplot PROPERTIES VERSION ${PROJECT_VERSION} SOVERSION ${PROJECT_VERSION_MAJOR})
# Shared library symbol export
include(GenerateExportHeader)
Alternatives I've considered
NA
Additional context
I am a packager for openSUSE and am working on submitting matplot++ packages to the distro's official repository.
Feature category
The problem This is a request to add an
SOVERSION
to the shared librarylibmatplot
that may only be incremented to indicate breakage or interface changes. According to TLDP,The solution I'd like
Ideally the soversion will be the major version, i.e.
1
formatplot++
1.2.x. This patch does it:Alternatives I've considered
NA
Additional context
I am a packager for openSUSE and am working on submitting matplot++ packages to the distro's official repository.
Thanks a lot for your very useful library.