build(meson): generate and install scdoc manpages
parent
2f5778d4cc
commit
92efe9af88
|
@ -0,0 +1,22 @@
|
||||||
|
manpages = {
|
||||||
|
'pc': 5,
|
||||||
|
'pkgconf': 1
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach page, section : manpages
|
||||||
|
name = '@0@.@1@'.format(page, section)
|
||||||
|
input = name + '.scd'
|
||||||
|
tgt = custom_target(
|
||||||
|
input,
|
||||||
|
input: files(input),
|
||||||
|
output: name,
|
||||||
|
capture: true,
|
||||||
|
feed: true,
|
||||||
|
command: scdoc,
|
||||||
|
install: true,
|
||||||
|
install_dir: get_option('mandir') / 'man@0@'.format(section),
|
||||||
|
)
|
||||||
|
endforeach
|
||||||
|
|
||||||
|
install_man('pkg.m4.7')
|
||||||
|
install_man('pkgconf-personality.5')
|
13
meson.build
13
meson.build
|
@ -1,7 +1,7 @@
|
||||||
project('pkgconf', 'c',
|
project('pkgconf', 'c',
|
||||||
version : '1.9.3',
|
version : '1.9.3',
|
||||||
license : 'ISC',
|
license : 'ISC',
|
||||||
meson_version : '>=0.49',
|
meson_version : '>=0.59',
|
||||||
default_options : ['c_std=c99'],
|
default_options : ['c_std=c99'],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -124,10 +124,13 @@ kyuafile = configure_file(input : 'Kyuafile.in', output : 'Kyuafile', configurat
|
||||||
test('kyua', kyua_exe, args : ['--config=none', 'test', '--kyuafile', kyuafile, '--build-root', meson.current_build_dir()])
|
test('kyua', kyua_exe, args : ['--config=none', 'test', '--kyuafile', kyuafile, '--build-root', meson.current_build_dir()])
|
||||||
subdir('tests')
|
subdir('tests')
|
||||||
|
|
||||||
install_man('man/pkgconf.1')
|
# https://github.com/mesonbuild/meson/issues/1550
|
||||||
install_man('man/pkg.m4.7')
|
# https://github.com/mesonbuild/meson/pull/9342
|
||||||
install_man('man/pc.5')
|
scdoc = find_program('scdoc', required: false)
|
||||||
install_man('man/pkgconf-personality.5')
|
if scdoc.found()
|
||||||
|
subdir('man')
|
||||||
|
endif
|
||||||
|
|
||||||
install_data('pkg.m4', install_dir: 'share/aclocal')
|
install_data('pkg.m4', install_dir: 'share/aclocal')
|
||||||
install_data('AUTHORS', install_dir: 'share/doc/pkgconf')
|
install_data('AUTHORS', install_dir: 'share/doc/pkgconf')
|
||||||
install_data('README.md', install_dir: 'share/doc/pkgconf')
|
install_data('README.md', install_dir: 'share/doc/pkgconf')
|
||||||
|
|
Loading…
Reference in New Issue