From: Michal Privoznik Date: Tue, 4 Mar 2025 08:23:51 +0000 (+0100) Subject: meson: Convert attr_dep to dependency() X-Git-Tag: v11.6.0-rc1~36 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c2c165ea6c1b2bd2c66d65668e66abe2c04fbd74;p=thirdparty%2Flibvirt.git meson: Convert attr_dep to dependency() Currently, libattr is detected using cc.find_library() because at historically, the library was lacking pkg-config file. But that changed with libattr-2.4.48 (released 7+ years ago) and even prehistoric distros have it now. Switch to dependency(). Signed-off-by: Michal Privoznik Reviewed-by: Pavel Hrdina --- diff --git a/meson.build b/meson.build index 08521fe7ea..7fd0e835e9 100644 --- a/meson.build +++ b/meson.build @@ -919,8 +919,7 @@ if not get_option('apparmor_profiles').disabled() endif endif -# FIXME rewrite to use dependency() once we can use 2.4.48 -attr_dep = cc.find_library('attr', required: get_option('attr')) +attr_dep = dependency('libattr', required: get_option('attr')) if attr_dep.found() conf.set('WITH_LIBATTR', 1) endif