mirror of
https://git.libcamera.org/libcamera/libcamera.git
synced 2025-07-12 23:09:45 +03:00
libcamera: meson: Fix libyuv detection
We already fall back to a subproject to support the libyuv package when it can not be discovered through the usual dependency() mechanism. Unfortunately libyuv may be packaged without any corresponding pkg-config support as can be seen at [0], so further extend the dependency search by using an explicit cxx.find_library() call. [0] https://packages.debian.org/bookworm/amd64/libyuv-dev/filelist Signed-off-by: Dylan Aïssi <dylan.aissi@collabora.com> Tested-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
This commit is contained in:
parent
eb550486c7
commit
1ea124c7a3
1 changed files with 12 additions and 2 deletions
|
@ -29,8 +29,18 @@ endif
|
||||||
|
|
||||||
# libyuv, used by the Android adaptation layer and the virtual pipeline handler.
|
# libyuv, used by the Android adaptation layer and the virtual pipeline handler.
|
||||||
# Fallback to a subproject if libyuv isn't found, as it's typically not provided
|
# Fallback to a subproject if libyuv isn't found, as it's typically not provided
|
||||||
# by distributions.
|
# by distributions. Where libyuv is provided by a distribution, it may not
|
||||||
libyuv_dep = dependency('libyuv', required : false)
|
# always supply a pkg-config implementation, requiring cxx.find_library() to
|
||||||
|
# search for it.
|
||||||
|
if not get_option('force_fallback_for').contains('libyuv')
|
||||||
|
libyuv_dep = dependency('libyuv', required : false)
|
||||||
|
if not libyuv_dep.found()
|
||||||
|
libyuv_dep = cxx.find_library('yuv', has_headers : 'libyuv.h',
|
||||||
|
required : false)
|
||||||
|
endif
|
||||||
|
else
|
||||||
|
libyuv_dep = dependency('', required : false)
|
||||||
|
endif
|
||||||
|
|
||||||
if (pipelines.contains('virtual') or get_option('android').allowed()) and \
|
if (pipelines.contains('virtual') or get_option('android').allowed()) and \
|
||||||
not libyuv_dep.found()
|
not libyuv_dep.found()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue