mirror of
https://git.libcamera.org/libcamera/libcamera.git
synced 2025-07-16 08:55:06 +03:00
apps: Move libevent dependency to src/apps/meson.build
libevent is a shared dependency between cam and lc-compliance, move it to src/apps/. The shared dependency will be used to condition compilation of source files in an upcoming application static library. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Paul Elder <paul.elder@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
This commit is contained in:
parent
84ad104499
commit
cd5439fb97
3 changed files with 12 additions and 5 deletions
|
@ -1,8 +1,6 @@
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
# SPDX-License-Identifier: CC0-1.0
|
||||||
|
|
||||||
libevent = dependency('libevent_pthreads', required : get_option('cam'))
|
if opt_cam.disabled() or not libevent.found()
|
||||||
|
|
||||||
if not libevent.found()
|
|
||||||
cam_enabled = false
|
cam_enabled = false
|
||||||
subdir_done()
|
subdir_done()
|
||||||
endif
|
endif
|
||||||
|
|
|
@ -1,10 +1,9 @@
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
# SPDX-License-Identifier: CC0-1.0
|
||||||
|
|
||||||
libevent = dependency('libevent_pthreads', required : get_option('lc-compliance'))
|
|
||||||
libgtest = dependency('gtest', required : get_option('lc-compliance'),
|
libgtest = dependency('gtest', required : get_option('lc-compliance'),
|
||||||
fallback : ['gtest', 'gtest_dep'])
|
fallback : ['gtest', 'gtest_dep'])
|
||||||
|
|
||||||
if not (libevent.found() and libgtest.found())
|
if opt_lc_compliance.disabled() or not libevent.found() or not libgtest.found()
|
||||||
lc_compliance_enabled = false
|
lc_compliance_enabled = false
|
||||||
subdir_done()
|
subdir_done()
|
||||||
endif
|
endif
|
||||||
|
|
|
@ -1,5 +1,15 @@
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
# SPDX-License-Identifier: CC0-1.0
|
||||||
|
|
||||||
|
opt_cam = get_option('cam')
|
||||||
|
opt_lc_compliance = get_option('lc-compliance')
|
||||||
|
|
||||||
|
# libevent is needed by cam and lc-compliance. As they are both feature options,
|
||||||
|
# they can't be combined with simple boolean logic.
|
||||||
|
libevent = dependency('libevent_pthreads', required : opt_cam)
|
||||||
|
if not libevent.found()
|
||||||
|
libevent = dependency('libevent_pthreads', required : opt_lc_compliance)
|
||||||
|
endif
|
||||||
|
|
||||||
subdir('lc-compliance')
|
subdir('lc-compliance')
|
||||||
|
|
||||||
subdir('cam')
|
subdir('cam')
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue