-
Notifications
You must be signed in to change notification settings - Fork 33
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
67 lines (55 loc) · 2.19 KB
/
CMakeLists.txt
File metadata and controls
67 lines (55 loc) · 2.19 KB
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
#
# Copyright (c) 2025 Nordic Semiconductor ASA
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#
cmake_minimum_required(VERSION 3.20.0)
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
project(app_module_test)
test_runner_generate(src/main.c)
set(ASSET_TRACKER_TEMPLATE_DIR ../../..)
target_sources(app
PRIVATE
src/main.c
src/checks.c
${ASSET_TRACKER_TEMPLATE_DIR}/app/src/main.c
${ASSET_TRACKER_TEMPLATE_DIR}/app/src/common/message_channel.c
)
target_include_directories(app PRIVATE src)
zephyr_include_directories(${ZEPHYR_BASE}/include/zephyr/)
zephyr_include_directories(${ZEPHYR_BASE}/subsys/testsuite/include)
zephyr_include_directories(../../../app/src/common)
zephyr_include_directories(../../../app/src/modules/cloud)
zephyr_include_directories(../../../app/src/modules/battery)
zephyr_include_directories(../../../app/src/modules/button)
zephyr_include_directories(../../../app/src/modules/network)
zephyr_include_directories(../../../app/src/modules/environmental)
zephyr_include_directories(../../../app/src/modules/fota)
zephyr_include_directories(../../../app/src/modules/location)
zephyr_include_directories(../../../app/src/modules/led)
target_link_options(app PRIVATE --whole-archive)
add_compile_options(-Wno-return-type)
set_property(SOURCE ${ASSET_TRACKER_TEMPLATE_DIR}/app/src/main.c PROPERTY COMPILE_FLAGS
"-include ${CMAKE_CURRENT_SOURCE_DIR}/src/redef.h")
# Options that cannot be passed through Kconfig fragments
target_compile_definitions(app PRIVATE
-DCONFIG_APP_LOG_LEVEL=4
-DCONFIG_APP_PAYLOAD_CHANNEL_BUFFER_MAX_SIZE=100
-DCONFIG_APP_MODULE_TRIGGER_TIMEOUT_SECONDS=600
-DCONFIG_APP_CLOUD_LOG_LEVEL=0
-DCONFIG_APP_CLOUD_THREAD_STACK_SIZE=2048
-DCONFIG_APP_CLOUD_MESSAGE_QUEUE_SIZE=5
-DCONFIG_APP_CLOUD_BACKOFF_TYPE_LINEAR=1
-DCONFIG_APP_CLOUD_BACKOFF_INITIAL_SECONDS=6
-DCONFIG_APP_CLOUD_BACKOFF_LINEAR_INCREMENT_SECONDS=6
-DCONFIG_APP_CLOUD_BACKOFF_MAX_SECONDS=36
-DCONFIG_LTE_LC_CONN_EVAL_MODULE=1
-DCONFIG_LTE_LC_EDRX_MODULE=1
-DCONFIG_LTE_LC_PSM_MODULE=1
-DCONFIG_APP_MODULE_RECV_BUFFER_SIZE=1024
-DCOAP_CONTENT_FORMAT_APP_JSON=50
-DCONFIG_APP_BATTERY=1
-DCONFIG_APP_ENVIRONMENTAL=1
-DZEPHYR_INCLUDE_SYS_REBOOT_H_
-DCONFIG_APP_REQUEST_NETWORK_QUALITY=1
)