summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStéphane Cerveau <scerveau@collabora.com>2020-07-25 21:19:20 +0100
committerTim-Philipp Müller <tim@centricular.com>2020-07-25 21:19:20 +0100
commitd454f95a094383260d4231a87b9131e146e60743 (patch)
tree7f4f7b61b68d132e2c1ae5ecab5ba940987691bc
parented0470e81b2c0e07b1b41476ce487bb80380936a (diff)
meson: add a plugin summary
This summary displays a list of plugins which have been enabled. Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/65>
-rw-r--r--meson.build15
1 files changed, 15 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index 174b1e7a..7111f1e8 100644
--- a/meson.build
+++ b/meson.build
@@ -286,3 +286,18 @@ endif
configure_file(output : 'config.h', configuration : cdata)
run_command(python3, '-c', 'import shutil; shutil.copy("hooks/pre-commit.hook", ".git/hooks/pre-commit")')
+
+if meson.version().version_compare('>= 0.54')
+ plugin_names = []
+ foreach plugin: plugins
+ # FIXME: Use str.subtring() when we can depend on Meson 0.56
+ split = plugin.name().split('gst')
+ if split.length() == 2
+ plugin_names += [split[1]]
+ else
+ warning('Need substring API in meson >= 0.56 to properly parse plugin name: ' + plugin.name())
+ plugin_names += [plugin.name()]
+ endif
+ endforeach
+ summary({'Plugins':plugin_names}, list_sep: ', ')
+endif