-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
31 lines (24 loc) · 1.51 KB
/
CMakeLists.txt
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
#=============================================================================#
# Author: QueezyTheGreat #
# Date: 26.04.2011 #
# #
# Description: Arduino CMake example #
# #
#=============================================================================#
cmake_minimum_required(VERSION 3.0...3.19)
set(CMAKE_TOOLCHAIN_FILE ${CMAKE_SOURCE_DIR}/toolchain/ArduinoToolchain.cmake) # Arduino Toolchain
set ( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Os")
add_definitions(-DARDUINO_ARCH_AVR) # for conditional compilation
foreach(PLATFORM ${ARDUINO_PLATFORMS})
set(ARDUINO_BOARD_LIST ${ARDUINO_BOARD_LIST} ${${PLATFORM}_BOARDS})
endforeach()
set(ARDUINO_DEFAULT_BOARD uno CACHE STRING "Default Board") # Default Board ID, when not specified
set_property(CACHE ARDUINO_DEFAULT_BOARD PROPERTY STRINGS ${ARDUINO_BOARD_LIST})
set(${FIRMWARE_NAME}_PORT com3)
#====================================================================#
# Setup Project #
#====================================================================#
project(ArcticPantherArduino C CXX)
print_board_list()
print_programmer_list()
add_subdirectory(ArcticPanther) # add the source directory into build