[libpeas] meson: build loaders as modules instead of shared libraries



commit 6b8f695ac8acb0f6e39bce76f873398974cd661b
Author: Tom Schoonjans <Tom Schoonjans diamond ac uk>
Date:   Tue Sep 10 09:50:46 2019 +0100

    meson: build loaders as modules instead of shared libraries
    
    Also: ensure that the extension of the loader plugins is set to so on
    macOS

 loaders/lua5.1/meson.build  | 5 +++--
 loaders/python/meson.build  | 5 +++--
 loaders/python3/meson.build | 5 +++--
 meson.build                 | 2 ++
 4 files changed, 11 insertions(+), 6 deletions(-)
---
diff --git a/loaders/lua5.1/meson.build b/loaders/lua5.1/meson.build
index 9dfe010..cc44ec8 100644
--- a/loaders/lua5.1/meson.build
+++ b/loaders/lua5.1/meson.build
@@ -27,7 +27,7 @@ lua51_loader_c_args = [
   '-DLGI_MICRO_VERSION=@0@'.format(lua51_lgi_version_micro),
 ]
 
-lua51_loader_sha = shared_library(
+lua51_loader_sha = shared_module(
   lua51_loader_name,
   lua51_loader_c + lua51_loader_res,
   include_directories: rootdir,
@@ -37,5 +37,6 @@ lua51_loader_sha = shared_library(
   install_dir: join_paths(
     pkglibdir,
     'loaders',
-  )
+  ),
+  name_suffix: module_suffix
 )
diff --git a/loaders/python/meson.build b/loaders/python/meson.build
index 1629496..215f3ef 100644
--- a/loaders/python/meson.build
+++ b/loaders/python/meson.build
@@ -31,7 +31,7 @@ python2_loader_c_args = [
   '-DPYGOBJECT_MICRO_VERSION=@0@'.format(pygobject_version_micro),
 ]
 
-python2_loader_sha = shared_library(
+python2_loader_sha = shared_module(
   python2_loader_name,
   python2_loader_c + python2_loader_res,
   include_directories: rootdir,
@@ -41,5 +41,6 @@ python2_loader_sha = shared_library(
   install_dir: join_paths(
     pkglibdir,
     'loaders',
-  )
+  ),
+  name_suffix: module_suffix
 )
diff --git a/loaders/python3/meson.build b/loaders/python3/meson.build
index 5b350a0..a97c81e 100644
--- a/loaders/python3/meson.build
+++ b/loaders/python3/meson.build
@@ -31,7 +31,7 @@ python3_loader_c_args = [
   '-DPYGOBJECT_MICRO_VERSION=@0@'.format(pygobject_version_micro),
 ]
 
-python3_loader_sha = shared_library(
+python3_loader_sha = shared_module(
   python3_loader_name,
   python3_loader_c + python3_loader_res,
   include_directories: rootdir,
@@ -41,5 +41,6 @@ python3_loader_sha = shared_library(
   install_dir: join_paths(
     pkglibdir,
     'loaders',
-  )
+  ),
+  name_suffix: module_suffix
 )
diff --git a/meson.build b/meson.build
index 56813ab..b0290dc 100644
--- a/meson.build
+++ b/meson.build
@@ -133,9 +133,11 @@ add_project_arguments([
   '-DGLIB_VERSION_MAX_ALLOWED=GLIB_VERSION_@0@_@1@'.format(glib_major_version, glib_minor_version),
 ], language: 'c')
 
+module_suffix = []
 if build_machine.system() == 'darwin'
   config_h.set('OS_OSX', 1)
   add_languages('objc')
+  module_suffix = 'so'
 endif
 
 # Detect and set symbol visibility


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