2024-06-04 14:52:11 +08:00
|
|
|
idf_build_get_property(target IDF_TARGET)
|
|
|
|
if(${target} STREQUAL "linux")
|
|
|
|
return() # This component is not supported by the POSIX/Linux simulator
|
|
|
|
endif()
|
|
|
|
|
2023-10-27 13:57:39 +08:00
|
|
|
set(srcs)
|
|
|
|
set(public_include "include")
|
|
|
|
if(CONFIG_SOC_GPTIMER_SUPPORTED)
|
|
|
|
list(APPEND srcs "src/gptimer.c"
|
2024-06-04 14:52:11 +08:00
|
|
|
"src/gptimer_common.c")
|
2023-10-27 13:57:39 +08:00
|
|
|
endif()
|
|
|
|
|
|
|
|
if(CONFIG_SOC_TIMER_SUPPORT_ETM)
|
|
|
|
list(APPEND srcs "src/gptimer_etm.c")
|
|
|
|
endif()
|
|
|
|
|
|
|
|
idf_component_register(SRCS ${srcs}
|
|
|
|
INCLUDE_DIRS ${public_include}
|
2023-11-22 17:27:43 +08:00
|
|
|
REQUIRES "esp_pm"
|
2023-10-27 13:57:39 +08:00
|
|
|
LDFRAGMENTS "linker.lf"
|
|
|
|
)
|