This repository has been archived on 2023-07-17. You can view files and clone it, but cannot push or open issues or pull requests.
bl_mcu_sdk/CMakeLists.txt

20 lines
784 B
CMake
Raw Normal View History

cmake_minimum_required(VERSION 3.15)
2021-04-13 19:23:11 +08:00
set(CMAKE_TOOLCHAIN_FILE ${CMAKE_SOURCE_DIR}/tools/cmake/riscv64-unknown-elf-gcc.cmake)
include(${CMAKE_SOURCE_DIR}/drivers/${CHIP}_driver/cpu_flags.cmake)
2021-04-13 19:23:11 +08:00
include(${CMAKE_SOURCE_DIR}/tools/cmake/compiler_flags.cmake)
include(${CMAKE_SOURCE_DIR}/tools/cmake/tools.cmake)
PROJECT(${BOARD} C CXX ASM)
# set(CMAKE_VERBOSE_MAKEFILE ON)
2021-06-20 12:33:52 +08:00
ENABLE_LANGUAGE(ASM)
2021-04-13 19:23:11 +08:00
include_directories(${CMAKE_SOURCE_DIR}/common/misc)
include_directories(${CMAKE_SOURCE_DIR}/bsp/bsp_common/platform)
2021-04-27 12:35:37 +08:00
if(IS_DIRECTORY ${CMAKE_SOURCE_DIR}/bsp/board/${CHIP})
include_directories(${CMAKE_SOURCE_DIR}/bsp/board/${CHIP})
2021-06-20 12:33:52 +08:00
else()
message(FATAL_ERROR "${CMAKE_SOURCE_DIR}/bsp/board/${CHIP} is not exist")
2021-04-27 12:35:37 +08:00
endif()
2021-04-13 19:23:11 +08:00
search_application(${CMAKE_SOURCE_DIR}/${APP_DIR})