espressif_idf-extra-components/test_app/CMakeLists.txt

31 lines
1.5 KiB
CMake
Raw Normal View History

2021-12-10 09:09:26 +01:00
# The following lines of boilerplate have to be in your project's
# CMakeLists in this exact order for cmake to work correctly
cmake_minimum_required(VERSION 3.5)
2022-02-28 17:02:41 +01:00
include($ENV{IDF_PATH}/tools/cmake/version.cmake)
2021-12-10 09:09:26 +01:00
2022-02-28 17:02:41 +01:00
# Add newly added components to one of these lines:
# 1. Add here if the component is compatible with IDF >= v4.3
set(EXTRA_COMPONENT_DIRS ../libsodium ../expat ../cbor ../jsmn ../qrcode ../coap ../eigen ../fmt)
2022-02-21 11:24:31 +01:00
2022-02-28 17:02:41 +01:00
# 2. Add here if the component is compatible with IDF >= v4.4
2022-02-21 11:24:31 +01:00
if("${IDF_VERSION_MAJOR}.${IDF_VERSION_MINOR}" VERSION_GREATER_EQUAL "4.4")
list(APPEND EXTRA_COMPONENT_DIRS ../pid_ctrl ../esp_encrypted_img ../pcap ../esp_jpeg)
2022-02-21 11:24:31 +01:00
endif()
2022-02-28 17:02:41 +01:00
# 3. Add here if the component is compatible with IDF >= v5.0
2022-02-21 11:24:31 +01:00
if("${IDF_VERSION_MAJOR}.${IDF_VERSION_MINOR}" VERSION_GREATER_EQUAL "5.0")
2022-02-09 09:23:26 +01:00
list(APPEND EXTRA_COMPONENT_DIRS ../bdc_motor ../led_strip ../sh2lib ../nghttp ../esp_serial_slave_link)
2022-02-21 11:24:31 +01:00
endif()
2022-02-28 17:02:41 +01:00
# !This section should NOT be touched when adding new component!
# Take all components in EXTRA_COMPONENT_DIRS, strip leading '../' and add it to TEST_COMPONENTS
# The build system will build and link unit tests, if the component contains 'test' subdirectory
set(TEST_COMPONENTS "" CACHE STRING "List of components to test")
foreach (CMP_DIR ${EXTRA_COMPONENT_DIRS})
string(SUBSTRING ${CMP_DIR} 3 100 STRIPPED_CMP) # There should be no component name longer than 100 bytes...
list(APPEND TEST_COMPONENTS ${STRIPPED_CMP})
endforeach()
2021-12-10 09:09:26 +01:00
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
project(idf_extra_test_app)