fix soname versioning as suggested in #98
authorMichael Wallner <mike@php.net>
Wed, 23 Dec 2020 09:39:53 +0000 (10:39 +0100)
committerMichael Wallner <mike@php.net>
Wed, 23 Dec 2020 09:39:53 +0000 (10:39 +0100)
CMakeVersions.txt
src/libhashkit/CMakeLists.txt
src/libmemcached/CMakeLists.txt
src/libmemcachedprotocol/CMakeLists.txt
src/libmemcachedutil/CMakeLists.txt

index aa77bdaa1815c2a76f1e7bec678cc61fb85f5952..81275015725bda3fb467ea7639b4669aa1878524 100644 (file)
@@ -22,11 +22,11 @@ endfunction()
 #
 
 set(LIBMEMCACHED_VERSION_MAJOR 1)
-set(LIBMEMCACHED_VERSION_MINOR 0)
-set(LIBMEMCACHED_VERSION_PATCH 99)
+set(LIBMEMCACHED_VERSION_MINOR 1)
+set(LIBMEMCACHED_VERSION_PATCH 0)
 
 set(LIBMEMCACHED_VERSION ${LIBMEMCACHED_VERSION_MAJOR}.${LIBMEMCACHED_VERSION_MINOR}.${LIBMEMCACHED_VERSION_PATCH})
-set(LIBMEMCACHED_VERSION_INC ${LIBMEMCACHED_VERSION_MAJOR}.${LIBMEMCACHED_VERSION_MINOR})
+set(LIBMEMCACHED_VERSION_INC ${LIBMEMCACHED_VERSION_MAJOR}.0)
 to_hex(LIBMEMCACHED_VERSION_HEX ${LIBMEMCACHED_VERSION_MAJOR} ${LIBMEMCACHED_VERSION_MINOR} ${LIBMEMCACHED_VERSION_PATCH})
 
 # libmemcached.so
@@ -35,6 +35,7 @@ set(LIBMEMCACHED_SO_VERSION_CUR 11)
 set(LIBMEMCACHED_SO_VERSION_REV 0)
 set(LIBMEMCACHED_SO_VERSION_AGE 0)
 
+set(LIBMEMCACHED_SO_SOVERSION ${LIBMEMCACHED_SO_VERSION_CUR}.${LIBMEMCACHED_SO_VERSION_REV})
 set(LIBMEMCACHED_SO_VERSION ${LIBMEMCACHED_SO_VERSION_CUR}.${LIBMEMCACHED_SO_VERSION_REV}.${LIBMEMCACHED_SO_VERSION_AGE})
 
 #
@@ -42,11 +43,11 @@ set(LIBMEMCACHED_SO_VERSION ${LIBMEMCACHED_SO_VERSION_CUR}.${LIBMEMCACHED_SO_VER
 #
 
 set(LIBMEMCACHEDUTIL_VERSION_MAJOR 1)
-set(LIBMEMCACHEDUTIL_VERSION_MINOR 0)
+set(LIBMEMCACHEDUTIL_VERSION_MINOR 1)
 set(LIBMEMCACHEDUTIL_VERSION_PATCH 0)
 
 set(LIBMEMCACHEDUTIL_VERSION ${LIBMEMCACHEDUTIL_VERSION_MAJOR}.${LIBMEMCACHEDUTIL_VERSION_MINOR}.${LIBMEMCACHEDUTIL_VERSION_PATCH})
-set(LIBMEMCACHEDUTIL_VERSION_INC ${LIBMEMCACHEDUTIL_VERSION_MAJOR}.${LIBMEMCACHEDUTIL_VERSION_MINOR})
+set(LIBMEMCACHEDUTIL_VERSION_INC ${LIBMEMCACHEDUTIL_VERSION_MAJOR}.0)
 to_hex(LIBMEMCACHEDUTIL_VERSION_HEX ${LIBMEMCACHEDUTIL_VERSION_MAJOR} ${LIBMEMCACHEDUTIL_VERSION_MINOR} ${LIBMEMCACHEDUTIL_VERSION_PATCH})
 
 # libmemcachedutil.so
@@ -55,6 +56,7 @@ set(LIBMEMCACHEDUTIL_SO_VERSION_CUR 2)
 set(LIBMEMCACHEDUTIL_SO_VERSION_REV 0)
 set(LIBMEMCACHEDUTIL_SO_VERSION_AGE 0)
 
+set(LIBMEMCACHEDUTIL_SO_SOVERSION ${LIBMEMCACHEDUTIL_SO_VERSION_CUR}.${LIBMEMCACHEDUTIL_SO_VERSION_REV})
 set(LIBMEMCACHEDUTIL_SO_VERSION ${LIBMEMCACHEDUTIL_SO_VERSION_CUR}.${LIBMEMCACHEDUTIL_SO_VERSION_REV}.${LIBMEMCACHEDUTIL_SO_VERSION_AGE})
 
 #
@@ -62,11 +64,11 @@ set(LIBMEMCACHEDUTIL_SO_VERSION ${LIBMEMCACHEDUTIL_SO_VERSION_CUR}.${LIBMEMCACHE
 #
 
 set(LIBMEMCACHEDPROTOCOL_VERSION_MAJOR 0)
-set(LIBMEMCACHEDPROTOCOL_VERSION_MINOR 0)
+set(LIBMEMCACHEDPROTOCOL_VERSION_MINOR 1)
 set(LIBMEMCACHEDPROTOCOL_VERSION_PATCH 0)
 
 set(LIBMEMCACHEDPROTOCOL_VERSION ${LIBMEMCACHEDPROTOCOL_VERSION_MAJOR}.${LIBMEMCACHEDPROTOCOL_VERSION_MINOR}.${LIBMEMCACHEDPROTOCOL_VERSION_PATCH})
-set(LIBMEMCACHEDPROTOCOL_VERSION_INC ${LIBMEMCACHEDPROTOCOL_VERSION_MAJOR}.${LIBMEMCACHEDPROTOCOL_VERSION_MINOR})
+set(LIBMEMCACHEDPROTOCOL_VERSION_INC ${LIBMEMCACHEDPROTOCOL_VERSION_MAJOR}.0)
 to_hex(LIBMEMCACHEDPROTOCOL_VERSION_HEX ${LIBMEMCACHEDPROTOCOL_VERSION_MAJOR} ${LIBMEMCACHEDPROTOCOL_VERSION_MINOR} ${LIBMEMCACHEDPROTOCOL_VERSION_PATCH})
 
 # libmemcachedprotocol.so
@@ -75,6 +77,7 @@ set(LIBMEMCACHEDPROTOCOL_SO_VERSION_CUR 0)
 set(LIBMEMCACHEDPROTOCOL_SO_VERSION_REV 0)
 set(LIBMEMCACHEDPROTOCOL_SO_VERSION_AGE 0)
 
+set(LIBMEMCACHEDPROTOCOL_SO_SOVERSION ${LIBMEMCACHEDPROTOCOL_SO_VERSION_CUR}.${LIBMEMCACHEDPROTOCOL_SO_VERSION_REV})
 set(LIBMEMCACHEDPROTOCOL_SO_VERSION ${LIBMEMCACHEDPROTOCOL_SO_VERSION_CUR}.${LIBMEMCACHEDPROTOCOL_SO_VERSION_REV}.${LIBMEMCACHEDPROTOCOL_SO_VERSION_AGE})
 
 #
@@ -82,11 +85,11 @@ set(LIBMEMCACHEDPROTOCOL_SO_VERSION ${LIBMEMCACHEDPROTOCOL_SO_VERSION_CUR}.${LIB
 #
 
 set(LIBHASHKIT_VERSION_MAJOR 1)
-set(LIBHASHKIT_VERSION_MINOR 0)
+set(LIBHASHKIT_VERSION_MINOR 1)
 set(LIBHASHKIT_VERSION_PATCH 0)
 
 set(LIBHASHKIT_VERSION ${LIBHASHKIT_VERSION_MAJOR}.${LIBHASHKIT_VERSION_MINOR}.${LIBHASHKIT_VERSION_PATCH})
-set(LIBHASHKIT_VERSION_INC ${LIBHASHKIT_VERSION_MAJOR}.${LIBHASHKIT_VERSION_MINOR})
+set(LIBHASHKIT_VERSION_INC ${LIBHASHKIT_VERSION_MAJOR}.0)
 to_hex(LIBHASHKIT_VERSION_HEX ${LIBHASHKIT_VERSION_MAJOR} ${LIBHASHKIT_VERSION_MINOR} ${LIBHASHKIT_VERSION_PATCH})
 
 # libhashkit.so
@@ -95,4 +98,5 @@ set(LIBHASHKIT_SO_VERSION_CUR 2)
 set(LIBHASHKIT_SO_VERSION_REV 0)
 set(LIBHASHKIT_SO_VERSION_AGE 0)
 
+set(LIBHASHKIT_SO_SOVERSION ${LIBHASHKIT_SO_VERSION_CUR}.${LIBHASHKIT_SO_VERSION_REV})
 set(LIBHASHKIT_SO_VERSION ${LIBHASHKIT_SO_VERSION_CUR}.${LIBHASHKIT_SO_VERSION_REV}.${LIBHASHKIT_SO_VERSION_AGE})
index ae57244f00e60ff3b8a65c98a644e74752ec93e3..81129ef76873424c741701808d6ba03410438214 100644 (file)
@@ -27,7 +27,8 @@ set_target_properties(libhashkit PROPERTIES
         CXX_STANDARD ${CXX_STANDARD}
         LIBRARY_OUTPUT_NAME hashkit
         LIBRARY_OUTPUT_NAME_DEBUG hashkit-dbg
-        SOVERSION ${LIBHASHKIT_SO_VERSION})
+        SOVERSION ${LIBHASHKIT_SO_SOVERSION}
+        VERSION ${LIBHASHKIT_SO_VERSION})
 target_compile_options(libhashkit PRIVATE -DBUILDING_HASHKIT)
 target_include_directories(libhashkit PRIVATE
         ${CMAKE_SOURCE_DIR}/src
index c688c7b95afc6af48bee29e9544b5eb50d320ad8..ebc5a213cdfcce2d58ac674c27724ddaae988fe1 100644 (file)
@@ -91,7 +91,8 @@ set_target_properties(libmemcached PROPERTIES
         CXX_STANDARD ${CXX_STANDARD}
         LIBRARY_OUTPUT_NAME memcached
         LIBRARY_OUTPUT_NAME_DEBUG memcached-dbg
-        SOVERSION ${LIBMEMCACHED_SO_VERSION})
+        SOVERSION ${LIBMEMCACHED_SO_SOVERSION}
+        VERSION ${LIBMEMCACHED_SO_VERSION})
 target_compile_definitions(libmemcached PRIVATE -DBUILDING_LIBMEMCACHED)
 target_link_libraries(libmemcached PUBLIC libhashkit Threads::Threads ${CMAKE_DL_LIBS})
 target_link_libraries(libmemcached PRIVATE p9y)
index 74658008c89d27d8f0f99934a477aad0c5f1f5e5..3e69aad9af329e7aa092b90279323fe8a0ef30c0 100644 (file)
@@ -14,7 +14,8 @@ set_target_properties(libmemcachedprotocol PROPERTIES
         CXX_STANDARD ${CXX_STANDARD}
         LIBRARY_OUTPUT_NAME memcachedprotocol
         LIBRARY_OUTPUT_NAME_DEBUG memcachedprotocol-dbg
-        SOVERSION ${LIBMEMCACHEDPROTOCOL_SO_VERSION})
+        SOVERSION ${LIBMEMCACHEDPROTOCOL_SO_SOVERSION}
+        VERSION ${LIBMEMCACHEDPROTOCOL_SO_VERSION})
 target_compile_definitions(libmemcachedprotocol PRIVATE -DBUILDING_LIBMEMCACHED)
 if(CMAKE_CXX_COMPILER_ID STREQUAL AppleClang)
        set_target_properties(libmemcachedprotocol PROPERTIES
index e08de1884d47fdc93b34a2a65bb4867a324b9e3b..88f1e8dfe13786607d7d1c196167815a600fdfa0 100644 (file)
@@ -15,7 +15,8 @@ set_target_properties(libmemcachedutil PROPERTIES
         CXX_STANDARD ${CXX_STANDARD}
         LIBRARY_OUTPUT_NAME memcachedutil
         LIBRARY_OUTPUT_NAME_DEBUG memcachedutil-dbg
-        SOVERSION ${LIBMEMCACHEDUTIL_SO_VERSION})
+        SOVERSION ${LIBMEMCACHEDUTIL_SO_SOVERSION}
+        VERSION ${LIBMEMCACHEDUTIL_SO_VERSION})
 target_compile_definitions(libmemcachedutil PRIVATE -DBUILDING_LIBMEMCACHED)
 if(CMAKE_CXX_COMPILER_ID STREQUAL AppleClang)
        set_target_properties(libmemcachedutil PROPERTIES