2020-12-13 22:10:29 -05:00
|
|
|
|
set(srcs "src/core_dump_common.c"
|
|
|
|
|
"src/core_dump_flash.c"
|
|
|
|
|
"src/core_dump_uart.c"
|
|
|
|
|
"src/core_dump_elf.c"
|
2024-01-10 07:41:18 -05:00
|
|
|
|
"src/core_dump_binary.c"
|
|
|
|
|
"src/core_dump_sha.c"
|
|
|
|
|
"src/core_dump_crc.c")
|
2020-12-13 22:10:29 -05:00
|
|
|
|
|
2021-03-01 05:30:35 -05:00
|
|
|
|
set(includes "include")
|
2020-12-13 22:10:29 -05:00
|
|
|
|
set(priv_includes "include_core_dump")
|
|
|
|
|
|
|
|
|
|
idf_build_get_property(target IDF_TARGET)
|
|
|
|
|
|
|
|
|
|
if(CONFIG_IDF_TARGET_ARCH_XTENSA)
|
2021-03-01 05:30:35 -05:00
|
|
|
|
list(APPEND srcs "src/port/xtensa/core_dump_port.c")
|
|
|
|
|
list(APPEND includes "include/port/xtensa")
|
|
|
|
|
list(APPEND priv_includes "include_core_dump/port/xtensa")
|
2020-12-13 22:10:29 -05:00
|
|
|
|
elseif(CONFIG_IDF_TARGET_ARCH_RISCV)
|
2021-03-01 05:30:35 -05:00
|
|
|
|
list(APPEND srcs "src/port/riscv/core_dump_port.c")
|
|
|
|
|
list(APPEND includes "include/port/riscv")
|
|
|
|
|
list(APPEND priv_includes "include_core_dump/port/riscv")
|
2020-12-13 22:10:29 -05:00
|
|
|
|
endif()
|
|
|
|
|
|
|
|
|
|
idf_component_register(SRCS ${srcs}
|
2021-03-01 05:30:35 -05:00
|
|
|
|
INCLUDE_DIRS ${includes}
|
2020-12-13 22:10:29 -05:00
|
|
|
|
PRIV_INCLUDE_DIRS ${priv_includes}
|
2019-06-21 02:29:32 -04:00
|
|
|
|
LDFRAGMENTS linker.lf
|
2022-10-14 08:15:32 -04:00
|
|
|
|
PRIV_REQUIRES esp_partition spi_flash bootloader_support mbedtls esp_rom soc esp_system driver)
|
2022-07-29 06:37:04 -04:00
|
|
|
|
|
|
|
|
|
if(CONFIG_ESP_COREDUMP_DATA_FORMAT_ELF)
|
|
|
|
|
target_link_libraries(${COMPONENT_LIB} PRIVATE idf::esp_app_format)
|
|
|
|
|
endif()
|