[gtk/gtk-3-24-meson: 82/89] meson: set soversion to 'vs<VSVer>' for MSVC



commit 7b771c29afd6e1ece8319bf85ad46dc9d1d08bb4
Author: Christoph Reiter <reiter christoph gmail com>
Date:   Wed Apr 3 20:59:28 2019 +0200

    meson: set soversion to 'vs<VSVer>' for MSVC
    
    This should result in <libname>-vs<VSVer>.dll filenames.

 meson.build | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)
---
diff --git a/meson.build b/meson.build
index 5e83ecb5d8..0c25957bb1 100644
--- a/meson.build
+++ b/meson.build
@@ -78,7 +78,14 @@ gtk_binary_version = '3.0.0'
 
 gtk_binary_age = 100 * gtk_minor_version + gtk_micro_version
 
-gtk_soversion = '0'
+cc = meson.get_compiler('c')
+
+if cc.get_id() == 'msvc'
+  gtk_soversion = 'vs@0@'.format(cc.version().split('.')[0])
+else
+  gtk_soversion = '0'
+endif
+
 gtk_osxversions = [(100 * gtk_minor_version) + 1, '@0@.@1@.0'.format((100 * gtk_minor_version) + 1, 
gtk_micro_version)]
 
 gtk_api_version = '@0@.0'.format(gtk_major_version)
@@ -134,8 +141,6 @@ gtk_appdatadir = join_paths(gtk_datadir, 'metainfo')
 # multipress: is mplocaledir defined somewhere?
 gtk_mplocaledir = join_paths(gtk_prefix, get_option('localedir'))
 
-cc = meson.get_compiler('c')
-
 cdata = configuration_data()
 cdata.set_quoted('PACKAGE_VERSION', meson.project_version())
 cdata.set_quoted('GTK_LOCALEDIR', gtk_localedir)


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