Build System Updates
Updated MAX32690 and MAX78002 linker and cmake scripts to work with CMake + Ninja build system. Verified all example projects build with the tools/build.py script for both board, and both make and cmake build systems.
This commit is contained in:
@@ -88,7 +88,7 @@ function(add_board_target BOARD_TARGET)
|
|||||||
${PERIPH_SRC}/UART
|
${PERIPH_SRC}/UART
|
||||||
)
|
)
|
||||||
|
|
||||||
target_compile_options(${TARGET} PRIVATE
|
target_compile_options(${BOARD_TARGET} PRIVATE
|
||||||
-Wno-error=strict-prototypes
|
-Wno-error=strict-prototypes
|
||||||
)
|
)
|
||||||
update_board(${BOARD_TARGET})
|
update_board(${BOARD_TARGET})
|
||||||
@@ -139,10 +139,14 @@ function(family_configure_example TARGET RTOS)
|
|||||||
target_sources(${TARGET}-tinyusb PUBLIC
|
target_sources(${TARGET}-tinyusb PUBLIC
|
||||||
${TOP}/src/portable/analog/max32/dcd_max32.c
|
${TOP}/src/portable/analog/max32/dcd_max32.c
|
||||||
)
|
)
|
||||||
target_link_libraries(${TARGET}-tinyusb PUBLIC board_${BOARD})
|
target_compile_options(${TARGET} PRIVATE
|
||||||
|
-Wno-error=strict-prototypes
|
||||||
|
)
|
||||||
|
|
||||||
|
target_link_libraries(${TARGET}-tinyusb PUBLIC board_${BOARD})
|
||||||
target_compile_options(${TARGET}-tinyusb PRIVATE
|
target_compile_options(${TARGET}-tinyusb PRIVATE
|
||||||
-Wno-error=strict-prototypes
|
-Wno-error=strict-prototypes
|
||||||
)
|
)
|
||||||
|
|
||||||
# Link dependencies
|
# Link dependencies
|
||||||
target_link_libraries(${TARGET} PUBLIC board_${BOARD} ${TARGET}-tinyusb)
|
target_link_libraries(${TARGET} PUBLIC board_${BOARD} ${TARGET}-tinyusb)
|
||||||
|
@@ -151,6 +151,8 @@ SECTIONS {
|
|||||||
.heap (COPY):
|
.heap (COPY):
|
||||||
{
|
{
|
||||||
. = ALIGN(4);
|
. = ALIGN(4);
|
||||||
|
PROVIDE ( end = . );
|
||||||
|
PROVIDE ( _end = . );
|
||||||
*(.heap*)
|
*(.heap*)
|
||||||
__HeapLimit = ABSOLUTE(__StackLimit);
|
__HeapLimit = ABSOLUTE(__StackLimit);
|
||||||
} > SRAM
|
} > SRAM
|
||||||
|
@@ -86,7 +86,7 @@ function(add_board_target BOARD_TARGET)
|
|||||||
${PERIPH_SRC}/UART
|
${PERIPH_SRC}/UART
|
||||||
)
|
)
|
||||||
|
|
||||||
target_compile_options(${TARGET} PRIVATE
|
target_compile_options(${BOARD_TARGET} PRIVATE
|
||||||
-Wno-error=strict-prototypes
|
-Wno-error=strict-prototypes
|
||||||
-Wno-error=redundant-decls
|
-Wno-error=redundant-decls
|
||||||
)
|
)
|
||||||
@@ -133,6 +133,12 @@ function(family_configure_example TARGET RTOS)
|
|||||||
${CMAKE_CURRENT_FUNCTION_LIST_DIR}/boards/${BOARD}
|
${CMAKE_CURRENT_FUNCTION_LIST_DIR}/boards/${BOARD}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
target_compile_options(${TARGET} PRIVATE
|
||||||
|
-Wno-error=strict-prototypes
|
||||||
|
-Wno-error=redundant-decls
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
# Add TinyUSB target and port source
|
# Add TinyUSB target and port source
|
||||||
family_add_tinyusb(${TARGET} OPT_MCU_MAX78002 ${RTOS})
|
family_add_tinyusb(${TARGET} OPT_MCU_MAX78002 ${RTOS})
|
||||||
target_sources(${TARGET}-tinyusb PUBLIC
|
target_sources(${TARGET}-tinyusb PUBLIC
|
||||||
|
@@ -159,6 +159,8 @@ SECTIONS {
|
|||||||
.heap (COPY):
|
.heap (COPY):
|
||||||
{
|
{
|
||||||
. = ALIGN(4);
|
. = ALIGN(4);
|
||||||
|
PROVIDE ( end = . );
|
||||||
|
PROVIDE ( _end = . );
|
||||||
*(.heap*)
|
*(.heap*)
|
||||||
__HeapLimit = ABSOLUTE(__StackLimit);
|
__HeapLimit = ABSOLUTE(__StackLimit);
|
||||||
} > SRAM
|
} > SRAM
|
||||||
|
Reference in New Issue
Block a user