2020-12-29 00:20:24 -05:00
|
|
|
idf_build_get_property(target IDF_TARGET)
|
2020-04-17 15:34:56 -04:00
|
|
|
|
2021-12-23 01:12:47 -05:00
|
|
|
set(srcs "")
|
2022-01-21 04:13:48 -05:00
|
|
|
set(includes "")
|
|
|
|
|
|
|
|
if(CONFIG_SOC_ULP_SUPPORTED OR CONFIG_SOC_RISCV_COPROC_SUPPORTED)
|
2020-12-29 00:20:24 -05:00
|
|
|
|
2021-12-23 01:12:47 -05:00
|
|
|
list(APPEND srcs
|
2022-01-21 04:13:48 -05:00
|
|
|
"ulp_common/ulp_common.c")
|
|
|
|
|
|
|
|
list(APPEND includes
|
|
|
|
ulp_common/include
|
|
|
|
ulp_common/include/${target})
|
|
|
|
|
|
|
|
if(CONFIG_ULP_COPROC_TYPE_FSM)
|
|
|
|
list(APPEND srcs
|
|
|
|
"ulp_fsm/ulp.c"
|
|
|
|
"ulp_fsm/ulp_macro.c")
|
|
|
|
|
|
|
|
list(APPEND includes
|
2022-02-17 01:14:34 -05:00
|
|
|
ulp_fsm/include
|
|
|
|
ulp_fsm/include/${target})
|
2020-04-17 15:34:56 -04:00
|
|
|
|
2022-01-21 04:13:48 -05:00
|
|
|
elseif(CONFIG_ULP_COPROC_TYPE_RISCV)
|
2021-12-23 01:12:47 -05:00
|
|
|
list(APPEND srcs
|
2022-02-28 05:12:28 -05:00
|
|
|
"ulp_riscv/ulp_riscv.c"
|
|
|
|
"ulp_riscv/ulp_riscv_adc.c")
|
2022-01-21 04:13:48 -05:00
|
|
|
|
|
|
|
list(APPEND includes
|
|
|
|
ulp_riscv/include)
|
2021-12-23 01:12:47 -05:00
|
|
|
endif()
|
2020-12-29 00:20:24 -05:00
|
|
|
endif()
|
2021-12-23 01:12:47 -05:00
|
|
|
|
|
|
|
idf_component_register(SRCS ${srcs}
|
2022-02-28 05:12:28 -05:00
|
|
|
INCLUDE_DIRS ${includes}
|
|
|
|
REQUIRES driver)
|