summaryrefslogtreecommitdiffstats
path: root/src/sensors/doc/snippets/sensors/CMakeLists.txt
blob: 27480020cc270c27f631aae7b2e4d6e1d72ce40b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# Copyright (C) 2022 The Qt Company Ltd.
# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause

cmake_minimum_required(VERSION 3.16)
project(sensorsdocsnippet LANGUAGES CXX)

set(CMAKE_INCLUDE_CURRENT_DIR ON)

set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_AUTOUIC ON)

find_package(Qt6 COMPONENTS Core Sensors)

qt_add_executable(sensorsdocsnippet
    creating.cpp
    main.cpp
    mybackend.h
    plugin.cpp
    start.cpp
)

target_link_libraries(sensorsdocsnippet PUBLIC
        Qt::Sensors
)

if (GCC AND UNIX)
    target_link_libraries(sensorsdocsnippet PUBLIC
        rdynamic
        log
    )
endif()