This repository has been archived by the owner on Jun 25, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeListsPrivate.txt
44 lines (36 loc) · 2.65 KB
/
CMakeListsPrivate.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
32
33
34
35
36
37
38
39
40
41
42
43
44
# !!! WARNING !!! AUTO-GENERATED FILE, PLEASE DO NOT MODIFY IT AND USE
# https://docs.platformio.org/page/projectconf/section_env_build.html#build-flags
#
# If you need to override existing CMake configuration or add extra,
# please create `CMakeListsUser.txt` in the root of project.
# The `CMakeListsUser.txt` will not be overwritten by PlatformIO.
set(CMAKE_CONFIGURATION_TYPES "megaatmega2560" CACHE STRING "" FORCE)
set(PLATFORMIO_CMD "/usr/local/bin/platformio")
SET(CMAKE_C_COMPILER "$ENV{HOME}/.platformio/packages/toolchain-atmelavr/bin/avr-gcc")
SET(CMAKE_CXX_COMPILER "$ENV{HOME}/.platformio/packages/toolchain-atmelavr/bin/avr-g++")
SET(CMAKE_CXX_FLAGS_DISTRIBUTION "-fno-exceptions -fno-threadsafe-statics -fpermissive -std=gnu++11 -Os -Wall -ffunction-sections -fdata-sections -flto -mmcu=atmega2560")
SET(CMAKE_C_FLAGS_DISTRIBUTION "-std=gnu11 -fno-fat-lto-objects -Os -Wall -ffunction-sections -fdata-sections -flto -mmcu=atmega2560")
SET(CMAKE_C_STANDARD 11)
set(CMAKE_CXX_STANDARD 11)
if (CMAKE_BUILD_TYPE MATCHES "megaatmega2560")
add_definitions(-D'PLATFORMIO=40100')
add_definitions(-D'ARDUINO_AVR_MEGA2560')
add_definitions(-D'F_CPU=16000000L')
add_definitions(-D'ARDUINO_ARCH_AVR')
add_definitions(-D'ARDUINO=10808')
add_definitions(-D'__AVR_ATmega2560__')
include_directories("${CMAKE_CURRENT_LIST_DIR}/include")
include_directories("${CMAKE_CURRENT_LIST_DIR}/src")
include_directories("$ENV{HOME}/.platformio/packages/framework-arduino-avr/libraries/Wire/src")
include_directories("$ENV{HOME}/.platformio/packages/framework-arduino-avr/cores/arduino")
include_directories("$ENV{HOME}/.platformio/packages/framework-arduino-avr/variants/mega")
include_directories("$ENV{HOME}/.platformio/packages/framework-arduino-avr/libraries/EEPROM/src")
include_directories("$ENV{HOME}/.platformio/packages/framework-arduino-avr/libraries/HID/src")
include_directories("$ENV{HOME}/.platformio/packages/framework-arduino-avr/libraries/SPI/src")
include_directories("$ENV{HOME}/.platformio/packages/framework-arduino-avr/libraries/SoftwareSerial/src")
include_directories("$ENV{HOME}/.platformio/packages/toolchain-atmelavr/avr/include")
include_directories("$ENV{HOME}/.platformio/packages/toolchain-atmelavr/lib/gcc/avr/5.4.0/include")
include_directories("$ENV{HOME}/.platformio/packages/toolchain-atmelavr/lib/gcc/avr/5.4.0/include-fixed")
include_directories("$ENV{HOME}/.platformio/packages/tool-unity")
endif()
FILE(GLOB_RECURSE SRC_LIST "${CMAKE_CURRENT_LIST_DIR}/src/*.*" "${CMAKE_CURRENT_LIST_DIR}/lib/*.*" "${CMAKE_CURRENT_LIST_DIR}/.pio/libdeps/megaatmega2560/*.*")