qcam: meson: Use pkg-config method for qt5 dependencies

Meson searches for qmake to determine if QT5 is available to support the
optional qcam component.

When cross compiling, meson can incorrectly identify the host qmake
which will cause incorrect linkage and usage of system headers.

Set the dependency method to specify pkg-config which resolves the
issue.

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
This commit is contained in:
Kieran Bingham
2019-04-03 17:03:45 +07:00
parent 78552c818b
commit d5ca33f6c7

View File

@@ -8,7 +8,10 @@ qcam_sources = files([
])
import('qt5')
qt5_dep = dependency('qt5', modules: ['Core', 'Gui', 'Widgets'], required : false)
qt5_dep = dependency('qt5',
method : 'pkg-config',
modules : ['Core', 'Gui', 'Widgets'],
required : false)
if qt5_dep.found()
qcam = executable('qcam', qcam_sources,