2017-06-16 17:31:40 +02:00
|
|
|
manpage_conf = configuration_data()
|
|
|
|
|
manpage_conf.set('PACKAGE_NAME', meson.project_name())
|
|
|
|
|
manpage_conf.set('PACKAGE_VERSION', meson.project_version())
|
2021-09-03 10:47:11 +03:00
|
|
|
manpage_conf.set('PACKAGE_URL', 'https://pipewire.org')
|
2020-01-28 16:09:56 +01:00
|
|
|
manpage_conf.set('PACKAGE_BUGREPORT', 'https://gitlab.freedesktop.org/pipewire/pipewire/issues')
|
2018-08-17 10:18:41 +02:00
|
|
|
manpage_conf.set('PIPEWIRE_CONFIG_DIR', pipewire_configdir)
|
2021-05-20 12:35:27 +10:00
|
|
|
manpage_conf.set('PIPEWIRE_CONFDATADIR', pipewire_confdatadir)
|
2017-06-16 17:31:40 +02:00
|
|
|
|
2023-11-18 20:04:06 +02:00
|
|
|
module_manpage_list = []
|
|
|
|
|
foreach m : module_sources
|
|
|
|
|
name = m.split('.c').get(0)
|
2023-11-19 23:08:09 +02:00
|
|
|
module_manpage_list += f'``libpipewire-' + name + '(7)``'
|
2023-11-18 20:04:06 +02:00
|
|
|
endforeach
|
|
|
|
|
|
|
|
|
|
manpage_conf.set('LIBPIPEWIRE_MODULES', '\n- '.join(module_manpage_list))
|
|
|
|
|
|
2023-11-19 23:08:09 +02:00
|
|
|
pulse_module_manpage_list = []
|
|
|
|
|
foreach m : pipewire_module_protocol_pulse_sources
|
|
|
|
|
name = m.split('/').get(-1).split('.c').get(0)
|
|
|
|
|
if m.contains('/modules/') and name.startswith('module-')
|
|
|
|
|
pulse_module_manpage_list += f'``pipewire-pulse-@name@(7)``'
|
|
|
|
|
endif
|
|
|
|
|
endforeach
|
|
|
|
|
|
|
|
|
|
manpage_conf.set('PIPEWIRE_PULSE_MODULES', '\n- '.join(pulse_module_manpage_list))
|
|
|
|
|
|
2018-08-30 14:49:08 +02:00
|
|
|
manpages = [
|
2021-09-03 10:16:48 +03:00
|
|
|
'pipewire.1.rst.in',
|
2021-11-10 11:27:33 +10:00
|
|
|
'pipewire-pulse.1.rst.in',
|
2021-09-03 10:16:48 +03:00
|
|
|
'pipewire.conf.5.rst.in',
|
2023-11-20 00:44:23 +02:00
|
|
|
'pipewire-pulse.conf.5.rst.in',
|
2021-09-03 10:16:48 +03:00
|
|
|
'pw-cat.1.rst.in',
|
|
|
|
|
'pw-cli.1.rst.in',
|
2023-04-20 10:24:29 +02:00
|
|
|
'pw-config.1.rst.in',
|
2021-09-03 10:16:48 +03:00
|
|
|
'pw-dot.1.rst.in',
|
2023-11-18 17:51:49 +02:00
|
|
|
'pw-dump.1.rst.in',
|
2022-04-02 09:15:31 +02:00
|
|
|
'pw-link.1.rst.in',
|
2023-11-18 18:05:10 +02:00
|
|
|
'pw-loopback.1.rst.in',
|
2021-09-03 10:16:48 +03:00
|
|
|
'pw-metadata.1.rst.in',
|
|
|
|
|
'pw-mididump.1.rst.in',
|
|
|
|
|
'pw-mon.1.rst.in',
|
|
|
|
|
'pw-profiler.1.rst.in',
|
2022-03-05 00:26:35 +00:00
|
|
|
'pw-top.1.rst.in',
|
2023-11-18 20:04:06 +02:00
|
|
|
'libpipewire-modules.7.rst.in',
|
2023-11-19 23:08:09 +02:00
|
|
|
'pipewire-pulse-modules.7.rst.in',
|
2018-08-30 14:49:08 +02:00
|
|
|
]
|
2017-06-16 17:31:40 +02:00
|
|
|
|
2022-02-03 19:14:34 +01:00
|
|
|
if get_option('pipewire-jack').allowed()
|
2021-09-03 10:16:48 +03:00
|
|
|
manpages += 'pw-jack.1.rst.in'
|
2020-06-08 14:24:49 +01:00
|
|
|
endif
|
|
|
|
|
|
2022-01-20 21:06:54 +02:00
|
|
|
if not generate_manpages
|
|
|
|
|
subdir_done()
|
|
|
|
|
endif
|
|
|
|
|
|
2017-06-16 17:31:40 +02:00
|
|
|
foreach m : manpages
|
2021-09-03 10:16:48 +03:00
|
|
|
file = m.split('.rst.in').get(0)
|
|
|
|
|
rst = configure_file(input : m,
|
2021-09-30 10:01:43 +10:00
|
|
|
output : file + '.rst',
|
|
|
|
|
configuration : manpage_conf)
|
2021-04-15 15:18:03 +10:00
|
|
|
section = file.split('.').get(-1)
|
2018-08-30 14:49:08 +02:00
|
|
|
custom_target(file + '.target',
|
2021-09-30 10:01:43 +10:00
|
|
|
output : file,
|
|
|
|
|
input : rst,
|
|
|
|
|
command : [rst2man, '@INPUT@', '@OUTPUT@'],
|
|
|
|
|
install : true,
|
|
|
|
|
install_dir : get_option('mandir') / 'man' + section)
|
2017-06-16 17:31:40 +02:00
|
|
|
endforeach
|