]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
meson: fix yajl detection
authorOlaf Hering <olaf@aepfle.de>
Thu, 12 Nov 2020 23:01:39 +0000 (00:01 +0100)
committerAndrea Bolognani <abologna@redhat.com>
Fri, 13 Nov 2020 10:23:13 +0000 (11:23 +0100)
yajl_tree_parse is declared in yajl/yajl_tree.h
autoconf is more forgiving, the error did not trigger because
yajl_tree_parse is not actually used.

Fixes: 44b8df4cb4b3f0c143e0330f543812e6bcd5c9f0
Fixes: 88ab32a4e555f67dae3204fbc3bcf63d3da8ad2b
Signed-off-by: Olaf Hering <olaf@aepfle.de>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
meson.build

index 8133d094c8d901449a30e2eb7e5a39d0975f6ef9..cecaad199d4ce22e09ddd9693934cd652d3ad52c 100644 (file)
@@ -1468,7 +1468,7 @@ if not get_option('yajl').disabled()
   if not yajl_dep.found()
     yajl_dep = cc.find_library('yajl', required: get_option('yajl'))
     if yajl_dep.found()
-      has_func = cc.has_function('yajl_tree_parse', dependencies: yajl_dep, prefix: '#include <yajl/yajl_common.h>')
+      has_func = cc.has_function('yajl_tree_parse', dependencies: yajl_dep, prefix: '#include <yajl/yajl_tree.h>')
       if not has_func and get_option('yajl').enabled()
         error('yajl >= @0@ was not found'.format(yajl_version))
       elif not has_func