pidgin/pidgin

Parents 65cf7357277d
Children 0a4177bbb1c4
Convert the gplugin subproject to use the auto fallback stuff of dependency.

Testing Done:
Verified the the purples gir's loaded and were able to call into gplugin under python, when built as a subproject and against a system installed version.

Reviewed at https://reviews.imfreedom.org/r/937/
--- a/doc/reference/libpurple/meson.build Sat Sep 11 10:19:20 2021 -0500
+++ b/doc/reference/libpurple/meson.build Fri Sep 24 02:56:53 2021 -0500
@@ -31,7 +31,6 @@
# Extra options to supply to gtkdoc-fixxref
fixxref_args = [
- '--extra-dir=@0@'.format(gplugin_docpath),
]
libpurple_version_xml = configure_file(
--- a/doc/reference/pidgin/meson.build Sat Sep 11 10:19:20 2021 -0500
+++ b/doc/reference/pidgin/meson.build Fri Sep 24 02:56:53 2021 -0500
@@ -26,7 +26,6 @@
# Extra options to supply to fixxref
fixxref_args = [
- '--extra-dir=@0@'.format(gplugin_gtk_docpath),
'--extra-dir=@0@'.format(talkatu_docpath),
'--extra-dir=../libpurple',
]
--- a/finch/meson.build Sat Sep 11 10:19:20 2021 -0500
+++ b/finch/meson.build Fri Sep 24 02:56:53 2021 -0500
@@ -234,7 +234,7 @@
Finch_gir_includes = [
libgnt_gir[0],
- gplugin_gir,
+ 'GPlugin-1.0',
# subproject needs to be before libpurple in the repo so that
# meson will use our variables and not try to discover them from
# libpurple.
@@ -250,9 +250,6 @@
export_packages : 'finch',
nsversion : '@0@.@1@'.format(purple_major_version,
purple_minor_version),
- include_directories : [
- gplugin_include_directories,
- ],
install : true,
extra_args : ['-DFINCH_COMPILATION', '--quiet'])
endif
--- a/libpurple/meson.build Sat Sep 11 10:19:20 2021 -0500
+++ b/libpurple/meson.build Fri Sep 24 02:56:53 2021 -0500
@@ -321,7 +321,7 @@
introspection_sources = (purple_coreheaders + purple_builtheaders +
purple_mediaheaders)
- Purple_gir_includes = ['GObject-2.0', 'Gio-2.0', 'Gst-1.0', gplugin_gir]
+ Purple_gir_includes = ['GObject-2.0', 'Gio-2.0', 'Gst-1.0', 'GPlugin-1.0']
libpurple_gir = gnome.generate_gir(libpurple,
sources : introspection_sources,
@@ -332,9 +332,7 @@
export_packages : purple_filebase,
nsversion : '@0@.@1@'.format(purple_major_version,
purple_minor_version),
- include_directories : [
- gplugin_include_directories,
- ],
+ dependencies: [ gplugin_dep ],
install : true,
extra_args : ['-DPURPLE_COMPILATION', '--quiet'])
endif
--- a/meson.build Sat Sep 11 10:19:20 2021 -0500
+++ b/meson.build Fri Sep 24 02:56:53 2021 -0500
@@ -570,59 +570,14 @@
#######################################################################
# Check for GPlugin
#######################################################################
-gplugin_dep = dependency('gplugin', version : ['>=0.33.0', '<0.34.0'], required : false)
-if gplugin_dep.found()
- gplugin_docpath = gplugin_dep.get_pkgconfig_variable('prefix') / 'share/gtk-doc/html'
-
- if enable_introspection
- gplugin_gir = 'GPlugin-1.0'
- gplugin_include_directories = include_directories(
- gplugin_dep.get_pkgconfig_variable('prefix') / 'share/gir-1.0')
- else
- gplugin_include_directories = []
- endif
-
- if get_option('gtkui')
- gplugin_gtk_dep = dependency('gplugin-gtk', required : true)
+gplugin_dep = dependency('gplugin',
+ version : ['>=0.33.0', '<0.34.0'],
+ fallback : ['gplugin', 'gplugin_dep'])
- gplugin_gtk_docpath = gplugin_gtk_dep.get_pkgconfig_variable('prefix') / 'share/gtk-doc/html'
- if enable_introspection
- gplugin_gtk_gir = 'GPluginGtk-1.0'
- gplugin_gtk_include_directories = include_directories(
- gplugin_gtk_dep.get_pkgconfig_variable('prefix') / 'share/gir-1.0')
- else
- gplugin_gtk_include_directories = []
- endif
- endif
-else
- gplugin_proj = subproject('gplugin',
- default_options : [
- 'doc=' + get_option('doc').to_string(),
- 'introspection=' + enable_introspection.to_string(),
- 'nls=' + get_option('nls').to_string(),
- 'gtk3=' + get_option('gtkui').to_string(),
- ]
- )
-
- gplugin_dep = gplugin_proj.get_variable('gplugin_dep')
-
- gplugin_docpath = meson.project_build_root() / 'subprojects/gplugin/gplugin/reference/'
-
- if enable_introspection
- gplugin_gir = gplugin_proj.get_variable('gplugin_gir')[0]
- endif
- gplugin_include_directories = []
-
- if get_option('gtkui')
- gplugin_gtk_dep = gplugin_proj.get_variable('gplugin_gtk_dep')
-
- gplugin_gtk_docpath = meson.project_build_root() / 'subprojects/gplugin/gplugin-gtk/reference/'
-
- if enable_introspection
- gplugin_gtk_gir = gplugin_proj.get_variable('gplugin_gtk_gir')[0]
- endif
- gplugin_gtk_include_directories = []
- endif
+if get_option('gtkui')
+ gplugin_gtk_dep = dependency('gplugin-gtk',
+ version : ['>=0.33.0', '<0.34.0'],
+ fallback : ['gplugin-gtk', 'gplugin_gtk_dep'])
endif
#######################################################################
--- a/pidgin/meson.build Sat Sep 11 10:19:20 2021 -0500
+++ b/pidgin/meson.build Fri Sep 24 02:56:53 2021 -0500
@@ -315,8 +315,8 @@
introspection_sources = libpidgin_headers + libpidgin_prefs_headers
Pidgin_gir_includes = [
- 'GObject-2.0', 'Gtk-3.0',
- talkatu_gir, gplugin_gir, gplugin_gtk_gir,
+ 'GObject-2.0', 'Gtk-3.0', 'GPlugin-1.0', 'GPluginGtk-1.0',
+ talkatu_gir,
# subproject needs to be before libpurple in the repo so that
# meson will use our variables and not try to discover them from
# libpurple.
@@ -333,8 +333,6 @@
nsversion : '@0@.@1@'.format(purple_major_version,
purple_minor_version),
include_directories : [
- gplugin_include_directories,
- gplugin_gtk_include_directories,
talkatu_include_directories,
],
install : true,