spa: meson.build: look for libcamera under another name

libcamera commit ec7afef665a87eb389a5a4cb9ff35e9c24bbcc29 (2021-06-24)
changed the name of the generated pkg-config file from 'camera.pc'
to 'libcamera.pc'.

First look for the libcamera dependency under the new name 'libcamera',
and if that's not found, look for it under the older name 'camera'.

Fixes #1355
This commit is contained in:
Barnabás Pőcze 2021-06-27 15:40:02 +02:00 committed by Wim Taymans
parent 2b515b5e50
commit d06a2e2140

View file

@ -39,7 +39,15 @@ if not get_option('spa-plugins').disabled()
vulkan_dep = dependency('vulkan', disabler : true, version : '>= 1.1.69', required: get_option('vulkan'))
vulkan_headers = cc.has_header('vulkan/vulkan.h', dependencies : vulkan_dep)
#summary({'Vulkan': vulkan_headers}, bool_yn: true, section: 'Misc dependencies')
libcamera_dep = dependency('camera', required: get_option('libcamera'))
if not get_option('libcamera').disabled()
libcamera_dep = dependency('libcamera', required: false)
if not libcamera_dep.found()
libcamera_dep = dependency('camera', required: get_option('libcamera'))
endif
else
libcamera_dep = dependency('', required: false)
endif
summary({'libcamera': libcamera_dep.found()}, bool_yn: true, section: 'Backend')
# common dependencies