mirror of
https://github.com/hathach/tinyusb.git
synced 2025-03-13 10:13:46 +00:00
clang f7, update cmsis f7 to fix startup bug
This commit is contained in:
parent
b4d0303a26
commit
1e882c7c24
@ -1,5 +1,5 @@
|
||||
set(MCU_VARIANT stm32f769xx)
|
||||
set(JLINK_DEVICE stm32f769xx)
|
||||
set(JLINK_DEVICE stm32f769ni)
|
||||
|
||||
set(LD_FILE_GNU ${CMAKE_CURRENT_LIST_DIR}/STM32F769ZITx_FLASH.ld)
|
||||
|
||||
|
@ -11,5 +11,7 @@ CFLAGS += \
|
||||
# Linker
|
||||
LD_FILE_GCC = $(BOARD_PATH)/STM32F769ZITx_FLASH.ld
|
||||
|
||||
JLINK_DEVICE = stm32f769ni
|
||||
|
||||
# flash target using on-board stlink
|
||||
flash: flash-stlink
|
||||
|
@ -1,9 +1,5 @@
|
||||
include_guard()
|
||||
|
||||
if (NOT BOARD)
|
||||
message(FATAL_ERROR "BOARD not specified")
|
||||
endif ()
|
||||
|
||||
set(ST_FAMILY f7)
|
||||
set(ST_PREFIX stm32${ST_FAMILY}xx)
|
||||
|
||||
@ -29,7 +25,10 @@ function(add_board_target BOARD_TARGET)
|
||||
if (NOT TARGET ${BOARD_TARGET})
|
||||
# Startup & Linker script
|
||||
set(STARTUP_FILE_GNU ${ST_CMSIS}/Source/Templates/gcc/startup_${MCU_VARIANT}.s)
|
||||
set(STARTUP_FILE_Clang ${STARTUP_FILE_GNU})
|
||||
set(STARTUP_FILE_IAR ${ST_CMSIS}/Source/Templates/iar/startup_${MCU_VARIANT}.s)
|
||||
|
||||
set(LD_FILE_Clang ${LD_FILE_GNU})
|
||||
set(LD_FILE_IAR ${ST_CMSIS}/Source/Templates/iar/linker/${MCU_VARIANT}_flash.icf)
|
||||
|
||||
add_library(${BOARD_TARGET} STATIC
|
||||
@ -52,10 +51,8 @@ function(add_board_target BOARD_TARGET)
|
||||
${ST_CMSIS}/Include
|
||||
${ST_HAL_DRIVER}/Inc
|
||||
)
|
||||
target_compile_options(${BOARD_TARGET} PUBLIC
|
||||
)
|
||||
target_compile_definitions(${BOARD_TARGET} PUBLIC
|
||||
)
|
||||
#target_compile_options(${BOARD_TARGET} PUBLIC)
|
||||
#target_compile_definitions(${BOARD_TARGET} PUBLIC)
|
||||
|
||||
update_board(${BOARD_TARGET})
|
||||
|
||||
@ -63,9 +60,11 @@ function(add_board_target BOARD_TARGET)
|
||||
target_link_options(${BOARD_TARGET} PUBLIC
|
||||
"LINKER:--script=${LD_FILE_GNU}"
|
||||
-nostartfiles
|
||||
# nanolib
|
||||
--specs=nosys.specs
|
||||
--specs=nano.specs
|
||||
--specs=nosys.specs --specs=nano.specs
|
||||
)
|
||||
elseif (CMAKE_C_COMPILER_ID STREQUAL "Clang")
|
||||
target_link_options(${BOARD_TARGET} PUBLIC
|
||||
"LINKER:--script=${LD_FILE_Clang}"
|
||||
)
|
||||
elseif (CMAKE_C_COMPILER_ID STREQUAL "IAR")
|
||||
target_link_options(${BOARD_TARGET} PUBLIC
|
||||
|
@ -84,7 +84,7 @@ deps_optional = {
|
||||
'2615e866fa48fe1ff1af9e31c348813f2b19e7ec',
|
||||
'stm32f4'],
|
||||
'hw/mcu/st/cmsis_device_f7': ['https://github.com/STMicroelectronics/cmsis_device_f7.git',
|
||||
'fc676ef1ad177eb874eaa06444d3d75395fc51f4',
|
||||
'25b0463439303b7a38f0d27b161f7d2f3c096e79',
|
||||
'stm32f7'],
|
||||
'hw/mcu/st/cmsis_device_g0': ['https://github.com/STMicroelectronics/cmsis_device_g0.git',
|
||||
'3a23e1224417f3f2d00300ecd620495e363f2094',
|
||||
|
Loading…
x
Reference in New Issue
Block a user