meson: Set install_tag on some targets
authorXavier Claessens <xavier.claessens@collabora.com>
Mon, 12 Sep 2022 13:46:43 +0000 (09:46 -0400)
committerGStreamer Marge Bot <gitlab-merge-bot@gstreamer-foundation.org>
Tue, 20 Sep 2022 10:08:15 +0000 (10:08 +0000)
Trying to follow recommendation from Meson documentation:
https://mesonbuild.com/Installing.html#installation-tags

Move tools into 'bin' or 'bin-devel' categories to keep only libs and
plugins in the default 'runtime' category. This simplifies distribution
of GStreamer application skipping parts that are not needed, similarly
to what Cerbero does by hardcoding huge list of files.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3017>

meson.build
subprojects/gst-devtools/validate/tools/meson.build
subprojects/gst-plugins-bad/tools/meson.build
subprojects/gst-plugins-base/tools/meson.build
subprojects/gst-python/gi/overrides/meson.build
subprojects/gstreamer/data/bash-completion/helpers/meson.build
subprojects/gstreamer/data/meson.build
subprojects/gstreamer/libs/gst/helpers/meson.build
subprojects/gstreamer/tests/validate/meson.build
subprojects/gstreamer/tools/meson.build

index 706a0dd..0df45b3 100644 (file)
@@ -443,6 +443,7 @@ if building_full
       exe_name = '@0@-@1@'.format(tool, apiversion)
       extra_args = data.get('extra_c_args', [])
       sources = data.get('files')
+      install_tag = data.get('install_tag', 'bin')
       deps = []
       foreach d : data.get('deps', [])
         if d not in exposed_deps
@@ -453,6 +454,7 @@ if building_full
       executable(exe_name,
         sources,
         install: true,
+        install_tag: install_tag,
         include_directories : [configinc],
         dependencies : [gst_full_dep] + deps,
         c_args: extra_args + gst_c_args + ['-DG_LOG_DOMAIN="@0@"'.format(exe_name)],
index 63a1b99..88796e3 100644 (file)
@@ -50,13 +50,13 @@ endif
 if not get_option('tools').disabled()
 
   foreach tool, data: gst_tools
-    if data.has_key('config_data')
-    else
+    if not data.has_key('config_data')
       exe_name = '@0@-@1@'.format(tool, apiversion)
       executable(
         exe_name,
         data.get('files'),
         install: true,
+        install_tag: 'bin-devel',
         include_directories : inc_dirs,
         dependencies : data.get('deps'),
         c_args : [gst_c_args] + ['-DG_LOG_DOMAIN="@0@"'.format(exe_name)],
index dfba0f4..1b935cc 100644 (file)
@@ -1,6 +1,7 @@
 executable('gst-transcoder-' + api_version,
   'gst-transcoder.c', 'utils.c',
   install : true,
+  install_tag : 'bin',
   dependencies : [gst_dep, gstpbutils_dep, gst_transcoder_dep],
   c_args: ['-DG_LOG_DOMAIN="gst-transcoder-@0@"'.format(api_version)],
 )
index b553b07..ab49e83 100644 (file)
@@ -50,6 +50,7 @@ if not get_option('tools').disabled()
     executable(exe_name,
       data.get('files'),
       install: true,
+      install_tag: 'bin',
       include_directories : [configinc],
       dependencies : data.get('deps'),
       c_args: data.get('extra_c_args', []) + gst_plugins_base_args + ['-DG_LOG_DOMAIN="@0@"'.format(exe_name)],
index cac9a48..5977ee3 100644 (file)
@@ -7,6 +7,7 @@ gstpython = python.extension_module('_gi_gst',
     sources: ['gstmodule.c'],
     install: true,
     install_dir : pygi_override_dir,
+    install_tag: 'python-runtime',
     include_directories : [configinc],
     dependencies : [gst_dep, python_dep, pygobject_dep])
 
index c633a4b..160b2e5 100644 (file)
@@ -7,4 +7,4 @@ configure_file(input : 'gst.in',
     output : 'gst',
     install_dir : bash_helpers_dir,
     configuration : bash_helper_conf,
-    install_tag : 'runtime')
+    install_tag : 'bin')
index aafcb4f..ac01dc0 100644 (file)
@@ -2,10 +2,10 @@ if (bashcomp_found)
   subdir('bash-completion/helpers')
   install_data('bash-completion/completions/gst-launch-1.0',
     install_dir : bash_completions_dir,
-    install_tag : 'runtime')
+    install_tag : 'bin')
   install_data('bash-completion/completions/gst-inspect-1.0',
     install_dir : bash_completions_dir,
-    install_tag : 'runtime')
+    install_tag : 'bin')
 endif
 
 if host_system == 'android'
index 4aeacd1..543064c 100644 (file)
@@ -19,6 +19,7 @@ if bashcomp_found
     include_directories : [configinc],
     dependencies : [gst_dep],
     install_dir : helpers_install_dir,
+    install_tag : 'bin',
     install: true,
   )
 endif
index fa137c1..29e5264 100644 (file)
@@ -3,6 +3,7 @@ gst_tester = executable('gst-tester-' + apiversion,
     c_args : gst_c_args,
     include_directories : [configinc],
     install: true,
+    install_tag: 'bin-devel',
     dependencies : [gio_dep],
 )
 
index f51892c..cc1ec2f 100644 (file)
@@ -35,6 +35,7 @@ foreach tool : tools
     executable(exe_name,
       src_file,
       install: true,
+      install_tag: 'bin',
       include_directories : [configinc],
       dependencies : [glib_dep, gobject_dep, gmodule_dep, mathlib, gst_dep] + extra_deps,
       c_args: gst_c_args + extra_c_args + ['-DG_LOG_DOMAIN="@0@"'.format(exe_name)],