From: Fred Morcos Date: Fri, 18 Aug 2023 22:17:17 +0000 (+0200) Subject: Meson: Cleanup the ODBC dependency detection X-Git-Tag: rec-5.1.0-alpha1~80^2~184 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=290f4b90ae0ca188ef37d0e156a6fc962c1b2d01;p=thirdparty%2Fpdns.git Meson: Cleanup the ODBC dependency detection --- diff --git a/meson/odbc/meson.build b/meson/odbc/meson.build index dbc45dca2c..6f16477993 100644 --- a/meson/odbc/meson.build +++ b/meson/odbc/meson.build @@ -1,9 +1,6 @@ -# ODBC -# Outputs: deps_odbc +dep_odbc = dependency('odbc', required: false) -deps_odbc = dependency('odbc', required: false) - -if not deps_odbc.found() +if not dep_odbc.found() odbc_config = find_program('odbc_config', required: true) odbc_cflags_res = run_command(odbc_config, '--cflags', check: true) @@ -15,8 +12,15 @@ if not deps_odbc.found() odbc_version_res = run_command(odbc_config, '--version', check: true) odbc_version = odbc_version_res.stdout().strip() - deps_odbc = declare_dependency(compile_args: odbc_cflags, link_args: odbc_ldflags, version: odbc_version) + dep_odbc = declare_dependency( + compile_args: odbc_cflags, + link_args: odbc_ldflags, + version: odbc_version, + ) endif -summary('ODBC', deps_odbc.found(), bool_yn: true, section: 'Configuration') -summary('ODBC Version', deps_odbc.version(), section: 'Configuration') +summary('ODBC', dep_odbc.found(), bool_yn: true, section: 'ODBC') + +if dep_odbc.found() + summary('Version', dep_odbc.version(), section: 'ODBC') +endif