mirror of https://github.com/mpv-player/mpv
meson: bump required version to 0.62
This lets us use meson's custom dl dependency as well as the version method when checking rst2pdf's version.
This commit is contained in:
parent
6234a70920
commit
a3eb163303
16
meson.build
16
meson.build
|
@ -2,7 +2,7 @@ project('mpv',
|
||||||
'c',
|
'c',
|
||||||
license: ['GPL2+', 'LGPL2.1+'],
|
license: ['GPL2+', 'LGPL2.1+'],
|
||||||
version: files('./VERSION'),
|
version: files('./VERSION'),
|
||||||
meson_version: '>=0.60.3',
|
meson_version: '>=0.62.0',
|
||||||
default_options: [
|
default_options: [
|
||||||
'buildtype=debugoptimized',
|
'buildtype=debugoptimized',
|
||||||
'b_lundef=false',
|
'b_lundef=false',
|
||||||
|
@ -327,10 +327,10 @@ endif
|
||||||
|
|
||||||
features += {'ta-leak-report': get_option('ta-leak-report')}
|
features += {'ta-leak-report': get_option('ta-leak-report')}
|
||||||
|
|
||||||
libdl_dep = cc.find_library('dl', required: false)
|
libdl = dependency('dl', required: false)
|
||||||
features += {'libdl': cc.has_function('dlopen', dependencies: libdl_dep, prefix: '#include <dlfcn.h>')}
|
features += {'libdl': libdl.found()}
|
||||||
if features['libdl']
|
if features['libdl']
|
||||||
dependencies += libdl_dep
|
dependencies += libdl
|
||||||
endif
|
endif
|
||||||
|
|
||||||
cplugins = get_option('cplugins').require(
|
cplugins = get_option('cplugins').require(
|
||||||
|
@ -1592,10 +1592,7 @@ endif
|
||||||
rst2pdf = find_program('rst2pdf', required: get_option('pdf-build'))
|
rst2pdf = find_program('rst2pdf', required: get_option('pdf-build'))
|
||||||
features += {'pdf-build': rst2pdf.found()}
|
features += {'pdf-build': rst2pdf.found()}
|
||||||
if features['pdf-build']
|
if features['pdf-build']
|
||||||
rst2pdf_help = run_command(
|
dependency_file = rst2pdf.version().version_compare('>=0.100')
|
||||||
rst2pdf, '--help',
|
|
||||||
check: true, capture: true
|
|
||||||
).stdout()
|
|
||||||
datadir = get_option('datadir')
|
datadir = get_option('datadir')
|
||||||
custom_target('pdf-manpages',
|
custom_target('pdf-manpages',
|
||||||
input: manpage,
|
input: manpage,
|
||||||
|
@ -1603,8 +1600,7 @@ if features['pdf-build']
|
||||||
command: [
|
command: [
|
||||||
docutils_wrapper, rst2pdf,
|
docutils_wrapper, rst2pdf,
|
||||||
'-c', '-b', '1', '--repeat-table-rows',
|
'-c', '-b', '1', '--repeat-table-rows',
|
||||||
rst2pdf_help.contains('--record-dependencies') ?
|
dependency_file ? ['--record-dependencies', '@DEPFILE@'] : [],
|
||||||
['--record-dependencies', '@DEPFILE@'] : [],
|
|
||||||
'@INPUT@', '-o', '@OUTPUT@'],
|
'@INPUT@', '-o', '@OUTPUT@'],
|
||||||
depfile: 'mpv.pdf.dep',
|
depfile: 'mpv.pdf.dep',
|
||||||
install: true,
|
install: true,
|
||||||
|
|
Loading…
Reference in New Issue