[pango/nirbheek/fix-osx-versioning] meson: Set the compatibility version correctly on macOS



commit ef55e1928dabca0192218a03467fe975ed51963d
Author: Nirbheek Chauhan <nirbheek centricular com>
Date:   Fri Oct 12 21:14:23 2018 +0530

    meson: Set the compatibility version correctly on macOS
    
    Requires the latest Meson.
    
    Closes https://gitlab.gnome.org/GNOME/pango/issues/320

 meson.build       | 8 ++------
 pango/meson.build | 4 ++++
 2 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/meson.build b/meson.build
index aad51b4d..48c2981b 100644
--- a/meson.build
+++ b/meson.build
@@ -6,7 +6,7 @@ project('pango', 'c', 'cpp',
           'warning_level=1',
           'c_std=c99',
         ],
-        meson_version : '>= 0.47.0')
+        meson_version : '>= 0.48.0')
 
 add_project_arguments([ '-D_POSIX_C_SOURCE=200809L', '-D_POSIX_THREAD_SAFE_FUNCTIONS', '-D_GNU_SOURCE', ], 
language: 'c')
 
@@ -40,6 +40,7 @@ pango_conf.set('PANGO_VERSION_MICRO', pango_micro_version)
 # Maintain version scheme with libtool
 pango_soversion = 0
 pango_libversion = '@0@.@1@.@2@'.format(pango_soversion, (pango_binary_age - pango_interface_age), 
pango_interface_age)
+pango_osxversion = pango_binary_age + 1
 
 cc = meson.get_compiler('c')
 host_system = host_machine.system()
@@ -138,11 +139,6 @@ if host_machine.system() == 'linux'
   common_ldflags += cc.get_supported_link_arguments([ '-Wl,-Bsymbolic', '-Wl,-z,relro', '-Wl,-z,now', ])
 endif
 
-# Maintain compatibility with autotools on macOS
-if host_machine.system() == 'darwin'
-  common_ldflags += [ '-compatibility_version 1', '-current_version 1.0', ]
-endif
-
 # Functions
 checked_funcs = [
   'sysconf',
diff --git a/pango/meson.build b/pango/meson.build
index 0466915f..3424b096 100644
--- a/pango/meson.build
+++ b/pango/meson.build
@@ -111,6 +111,7 @@ libpango = library(
   sources: pango_sources + pango_enums,
   version: pango_libversion,
   soversion: pango_soversion,
+  darwin_versions : pango_osxversion,
   install: true,
   dependencies: pango_deps,
   include_directories: [ root_inc, pango_inc ],
@@ -206,6 +207,7 @@ if build_pangoft2
     sources: pangoft2_sources,
     version: pango_libversion,
     soversion: pango_soversion,
+    darwin_versions : pango_osxversion,
     install: true,
     dependencies: pango_deps + [ libpango_dep ],
     include_directories: [ root_inc, pango_inc ],
@@ -280,6 +282,7 @@ if xft_dep.found() and fontconfig_dep.found()
     sources: pangoxft_sources,
     version: pango_libversion,
     soversion: pango_soversion,
+    darwin_versions : pango_osxversion,
     install: true,
     dependencies: pango_deps + [ libpango_dep, libpangoft2_dep ],
     include_directories: [ root_inc, pango_inc ],
@@ -453,6 +456,7 @@ if cairo_dep.found()
     sources: pangocairo_sources,
     version: pango_libversion,
     soversion: pango_soversion,
+    darwin_versions : pango_osxversion,
     install: true,
     dependencies: pango_deps + pangocairo_deps,
     include_directories: [ root_inc, pango_inc ],


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]