mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-12-28 08:26:14 +01:00
gmodule: Define a gmodule include dependency and use it in gio modules
Various gio modules include gmodule.h that requires the
gmodule-visibility.h to be already built.
To make this easier, just provide a dependency and use it where we are
building modules that do not depend on libgio_dep (that already includes
that).
Fixes: https://gitlab.gnome.org/GNOME/glib/-/issues/2982
(cherry picked from commit fe38a02c62
)
This commit is contained in:
parent
e82348db62
commit
4ed5539d0a
@ -8,9 +8,14 @@ inotify_sources = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
inotify_lib = static_library('inotify',
|
inotify_lib = static_library('inotify',
|
||||||
sources : [inotify_sources, gmodule_visibility_h],
|
sources : [inotify_sources],
|
||||||
include_directories : [configinc, glibinc, gmoduleinc],
|
include_directories : [configinc, glibinc],
|
||||||
dependencies : [gioenumtypes_dep, libglib_dep, libgobject_dep],
|
dependencies : [
|
||||||
|
gioenumtypes_dep,
|
||||||
|
libglib_dep,
|
||||||
|
libgobject_dep,
|
||||||
|
gmodule_inc_dep,
|
||||||
|
],
|
||||||
gnu_symbol_visibility : 'hidden',
|
gnu_symbol_visibility : 'hidden',
|
||||||
pic : true,
|
pic : true,
|
||||||
c_args : [gio_c_args, gio_c_args_internal])
|
c_args : [gio_c_args, gio_c_args_internal])
|
||||||
|
@ -6,9 +6,12 @@ kqueue_sources = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
kqueue_lib = static_library('kqueue',
|
kqueue_lib = static_library('kqueue',
|
||||||
sources : kqueue_sources,
|
sources : [kqueue_sources],
|
||||||
include_directories : [configinc, glibinc, gmoduleinc],
|
include_directories : [configinc, glibinc],
|
||||||
dependencies : [gioenumtypes_dep],
|
dependencies : [
|
||||||
|
gioenumtypes_dep,
|
||||||
|
gmodule_inc_dep,
|
||||||
|
],
|
||||||
gnu_symbol_visibility : 'hidden',
|
gnu_symbol_visibility : 'hidden',
|
||||||
pic : true,
|
pic : true,
|
||||||
c_args : [gio_c_args, gio_c_args_internal])
|
c_args : [gio_c_args, gio_c_args_internal])
|
||||||
|
@ -9,8 +9,12 @@ giowin32_sources = [
|
|||||||
|
|
||||||
giowin32_lib = static_library('giowin32',
|
giowin32_lib = static_library('giowin32',
|
||||||
sources : [giowin32_sources],
|
sources : [giowin32_sources],
|
||||||
include_directories : [configinc, glibinc, gioinc, gmoduleinc],
|
include_directories : [configinc, glibinc, gioinc],
|
||||||
dependencies : [libintl, gioenumtypes_dep],
|
dependencies : [
|
||||||
|
libintl,
|
||||||
|
gioenumtypes_dep,
|
||||||
|
gmodule_inc_dep,
|
||||||
|
],
|
||||||
gnu_symbol_visibility : 'hidden',
|
gnu_symbol_visibility : 'hidden',
|
||||||
pic : true,
|
pic : true,
|
||||||
c_args : [gio_c_args, gio_c_args_internal])
|
c_args : [gio_c_args, gio_c_args_internal])
|
||||||
|
@ -135,10 +135,13 @@ pkg.generate(libraries : [libgmodule, export_dynamic_ldflags],
|
|||||||
description : 'Dynamic module loader for GLib',
|
description : 'Dynamic module loader for GLib',
|
||||||
)
|
)
|
||||||
|
|
||||||
|
gmodule_inc_dep = declare_dependency(
|
||||||
|
include_directories: [gmoduleinc],
|
||||||
|
sources: [gmodule_visibility_h],
|
||||||
|
)
|
||||||
|
|
||||||
libgmodule_dep = declare_dependency(link_with : libgmodule,
|
libgmodule_dep = declare_dependency(link_with : libgmodule,
|
||||||
include_directories : [gmoduleinc],
|
dependencies : [libglib_dep, gmodule_inc_dep])
|
||||||
sources : [gmodule_visibility_h],
|
|
||||||
dependencies : [libglib_dep])
|
|
||||||
|
|
||||||
meson.override_dependency('gmodule-no-export-2.0', libgmodule_dep)
|
meson.override_dependency('gmodule-no-export-2.0', libgmodule_dep)
|
||||||
meson.override_dependency('gmodule-export-2.0', libgmodule_dep)
|
meson.override_dependency('gmodule-export-2.0', libgmodule_dep)
|
||||||
|
Loading…
Reference in New Issue
Block a user