video: Add/fix various annotations
[platform/upstream/gstreamer.git] / subprojects / gstreamer / tools / meson.build
1 # If tools are disabled, we still allow building them against gst-full
2 # later, so populate the gst_tools dictionary in any case.
3 gst_tools = {}
4
5 tools = ['gst-inspect', 'gst-stats', 'gst-typefind']
6
7 extra_launch_dep = []
8 extra_launch_arg = []
9
10 if gst_parse
11   if host_system == 'windows' and not building_for_uwp
12     winmm_lib = cc.find_library('winmm', required: false)
13     if winmm_lib.found() and cc.has_header('mmsystem.h')
14       extra_launch_dep += [winmm_lib]
15       extra_launch_arg += ['-DHAVE_WINMM']
16     endif
17   endif
18
19   tools += ['gst-launch']
20 endif
21
22 foreach tool : tools
23   exe_name = '@0@-@1@'.format(tool, apiversion)
24   src_file = '@0@.c'.format(tool)
25   extra_deps = []
26   extra_c_args = []
27
28   if tool == 'gst-launch'
29     extra_deps += extra_launch_dep
30     extra_c_args += extra_launch_arg
31   endif
32
33   man_page = files('@0@-1.0.1'.format(tool))
34   if not get_option('tools').disabled()
35     executable(exe_name,
36       src_file,
37       install: true,
38       install_tag: 'bin',
39       include_directories : [configinc],
40       dependencies : [glib_dep, gobject_dep, gmodule_dep, mathlib, gst_dep] + extra_deps,
41       c_args: gst_c_args + extra_c_args + ['-DG_LOG_DOMAIN="@0@"'.format(exe_name)],
42     )
43
44     install_man(man_page)
45   endif
46
47   gst_tools += {tool:
48     {
49       'files': files(src_file),
50       'deps': [glib_dep, gobject_dep, gmodule_dep, mathlib, gst_dep] + extra_deps,
51       'extra_c_args': extra_c_args,
52       'man_page': man_page,
53     }
54   }
55 endforeach