Skip to content

Commit 5a7280d

Browse files
committed
meson: Pass more feature option through to required kwargs
That was already done in a lot of places, but not all. Backpatch this to keep the the meson files aligned as long as reasonably possible. Author: Tristan Partin <tristan@neon.tech> Reviewed-by: Andres Freund <andres@anarazel.de> Discussion: https://postgr.es/m/CSPIJVUDZFKX.3KHMOAVGF94RV@c3po Backpatch: 16-, where meson support was added
1 parent eeb28a2 commit 5a7280d

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

meson.build

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -769,8 +769,8 @@ endif
769769

770770
icuopt = get_option('icu')
771771
if not icuopt.disabled()
772-
icu = dependency('icu-uc', required: icuopt.enabled())
773-
icu_i18n = dependency('icu-i18n', required: icuopt.enabled())
772+
icu = dependency('icu-uc', required: icuopt)
773+
icu_i18n = dependency('icu-i18n', required: icuopt)
774774

775775
if icu.found()
776776
cdata.set('USE_ICU', 1)
@@ -1054,9 +1054,9 @@ endif
10541054
pyopt = get_option('plpython')
10551055
if not pyopt.disabled()
10561056
pm = import('python')
1057-
python3_inst = pm.find_installation(required: pyopt.enabled())
1058-
python3_dep = python3_inst.dependency(embed: true, required: pyopt.enabled())
1059-
if not cc.check_header('Python.h', dependencies: python3_dep, required: pyopt.enabled())
1057+
python3_inst = pm.find_installation(required: pyopt)
1058+
python3_dep = python3_inst.dependency(embed: true, required: pyopt)
1059+
if not cc.check_header('Python.h', dependencies: python3_dep, required: pyopt)
10601060
python3_dep = not_found_dep
10611061
endif
10621062
else
@@ -1079,7 +1079,7 @@ if not get_option('readline').disabled()
10791079
readline = dependency(readline_dep, required: false)
10801080
if not readline.found()
10811081
readline = cc.find_library(readline_dep,
1082-
required: get_option('readline').enabled(),
1082+
required: get_option('readline'),
10831083
dirs: test_lib_d)
10841084
endif
10851085
if readline.found()
@@ -1379,7 +1379,7 @@ if not zlibopt.disabled()
13791379
warning('did not find zlib')
13801380
elif not cc.has_header('zlib.h',
13811381
args: test_c_args, include_directories: postgres_inc,
1382-
dependencies: [zlib_t], required: zlibopt.enabled())
1382+
dependencies: [zlib_t], required: zlibopt)
13831383
warning('zlib header not found')
13841384
elif not cc.has_type('z_streamp',
13851385
dependencies: [zlib_t], prefix: '#include <zlib.h>',
@@ -2538,7 +2538,7 @@ if not nlsopt.disabled()
25382538
# otherwise there'd be lots of
25392539
# "Gettext not found, all translation (po) targets will be ignored."
25402540
# warnings if not found.
2541-
msgfmt = find_program('msgfmt', required: nlsopt.enabled(), native: true)
2541+
msgfmt = find_program('msgfmt', required: nlsopt, native: true)
25422542

25432543
# meson 0.59 has this wrapped in dependency('intl')
25442544
if (msgfmt.found() and

0 commit comments

Comments
 (0)