forked from pranjalchanda08/MeshX
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
41 lines (34 loc) · 1.74 KB
/
CMakeLists.txt
File metadata and controls
41 lines (34 loc) · 1.74 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
cmake_minimum_required(VERSION 3.20)
# ------------------------------------------------------------------------------
# Options
# ------------------------------------------------------------------------------
set(MESHX_VERSION "0.3.3" CACHE SREING "MESHX Build Version")
set(BSP "weact_c3" CACHE STRING "BSP Selection")
set(ELF meshx_build CACHE STRING "Name of the final executable")
set(PROD_PROFILE "port/bsp/${BSP}/prod_profile.yml" CACHE STRING "Path to the product profile YAML file")
option(ENABLE_TESTS "Enable building unit tests" OFF)
# ------------------------------------------------------------------------------
# INTERNAL CACHE VARIABLES
# ------------------------------------------------------------------------------
set(OS "FreeRTOS" CACHE INTERNAL "OS abstraction layer to be set by BSP")
set(SRC_FILES "" CACHE INTERNAL "Source files for the project")
set(INC_FILES "" CACHE INTERNAL "Include directories for the project")
set(PLAT_LIBS "" CACHE INTERNAL "Platform libraries to link against")
set(PLATFORM_TEST_SUPPORTED ON CACHE INTERNAL "Testing supported in platform")
# ------------------------------------------------------------------------------
# BSP
# ------------------------------------------------------------------------------
include(port/bsp/${BSP}/bsp.cmake)
# ------------------------------------------------------------------------------
# Remove duplicate source files
list(REMOVE_DUPLICATES SRC_FILES)
list(REMOVE_DUPLICATES INC_FILES)
# ------------------------------------------------------------------------------
include_directories(${INC_FILES})
message(STATUS "INC_FILES: ${INC_FILES}")
message(STATUS "PLAT_LIBS: ${PLAT_LIBS}")
project(${ELF}
VERSION ${MESHX_VERSION}
DESCRIPTION "MeshX"
LANGUAGES C
)