summaryrefslogtreecommitdiffstats
path: root/cmake/FindSensorfw.cmake
blob: c6238a92e12a2a2e888cfe6a11f179e57963c6d5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
# Copyright (C) 2022 The Qt Company Ltd.
# SPDX-License-Identifier: BSD-3-Clause

find_package(PkgConfig)
if (PKG_CONFIG_FOUND)
    pkg_check_modules(Sensorfw sensord-qt5 IMPORTED_TARGET)
    if (NOT TARGET PkgConfig::Sensorfw)
        set(Sensorfw_FOUND 0)
    endif()
else()
    message("Sensorfw pkg not found. Looking for library")
    find_library(Sensorfw sensorfw)
endif()