mirror of
https://github.com/hathach/tinyusb.git
synced 2025-01-17 05:32:55 +08:00
17 lines
521 B
CMake
17 lines
521 B
CMake
cmake_minimum_required(VERSION 3.5)
|
|
|
|
include(${CMAKE_CURRENT_SOURCE_DIR}/../../../hw/bsp/family_support.cmake)
|
|
|
|
# gets PROJECT name for the example (e.g. <BOARD>-<DIR_NAME>)
|
|
family_get_project_name(PROJECT ${CMAKE_CURRENT_LIST_DIR})
|
|
|
|
project(${PROJECT})
|
|
|
|
# Checks this example is valid for the family and initializes the project
|
|
family_initialize_project(${PROJECT} ${CMAKE_CURRENT_LIST_DIR})
|
|
|
|
# Check for -DFAMILY=
|
|
if(NOT FAMILY STREQUAL "espressif")
|
|
message(FATAL_ERROR "Invalid FAMILY specified: ${FAMILY}")
|
|
endif()
|