소스 검색

lib: use libtool like versioning

In order to be safe for future ABI changes and to fulfill packaging
requirements for e.g. Fedora, provide libtool like versioning for
both libraries, i.e. libgamemode and libgamemodeauto.
Christian Kellner 6 년 전
부모
커밋
ea3e135ae0
1개의 변경된 파일11개의 추가작업 그리고 0개의 파일을 삭제
  1. 11 0
      lib/meson.build

+ 11 - 0
lib/meson.build

@@ -1,3 +1,10 @@
+# Libtool like versioning (current.revision.age) for the libraries
+# See https://www.sourceware.org/autobook/autobook/autobook_61.html#Library-Versioning
+lt_current = '0'
+lt_revision = '0'
+lt_age = '0'
+lt_version = '@0@.@1@.@2@'.format(lt_current, lt_age, lt_revision)
+
 # Main client library to message the daemon
 gamemode = shared_library(
     'gamemode',
@@ -8,6 +15,8 @@ gamemode = shared_library(
         dep_systemd,
     ],
     install: true,
+    soversion: lt_current,
+    version: lt_version,
 )
 
 libgamemode_includes = [
@@ -24,6 +33,8 @@ gamemodeauto = shared_library(
         libdl,
     ],
     install: true,
+    soversion: lt_current,
+    version: lt_version,
 )
 
 # Install the gamemode_client header