-
Notifications
You must be signed in to change notification settings - Fork 2
/
CMakeLists.txt
31 lines (24 loc) · 1.02 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
# Basic CMake configuration
CMAKE_MINIMUM_REQUIRED (VERSION 3.6)
SET(PROJECT_ROOT_DIR_PATH ${CMAKE_CURRENT_SOURCE_DIR})
OPTION(DEFINE_DEBUG "Build the project using debugging code" OFF)
# Configure the GCC toolchain.
INCLUDE(${CMAKE_CURRENT_SOURCE_DIR}/sdk_cmake/armgcc.cmake)
# set(MK64F_LINKER_SCRIPT ${PROJECT_DIR_PATH}/linker/K64FN1M0xxx12.ld)
IF(NOT DEFINED FIRMWARE_TARGET)
message(FATAL_ERROR "FIRMWARE_TARGET NOT DEFINED")
ENDIF()
# !Set in gcc probably best to override with the ones belows
SET(EXECUTABLE_OUTPUT_PATH ${CMAKE_CURRENT_SOURCE_DIR}/bin/${FIRMWARE_TARGET})
SET(LIBRARY_OUTPUT_PATH ${CMAKE_CURRENT_SOURCE_DIR}/bin/${FIRMWARE_TARGET})
#IMPORTANT NOT MARIO KART 64 D:
project(MK64F_TEMPLATE C ASM)
# Load all the relevant git repository information.
INCLUDE(${CMAKE_CURRENT_SOURCE_DIR}/sdk_cmake/configure_versions.cmake)
if(NOT DEFINED DEBUG_MODE)
MESSAGE(STATUS "DEBUG MODE ENABLED")
ADD_DEFINITIONS(-DDEBUG)
else()
MESSAGE(STATUS "DEBUG MODE DISABLED")
endif()
add_subdirectory(fw-${FIRMWARE_TARGET})