2021-09-02 13:25:34 +00:00
|
|
|
idf_build_get_property(idf_target IDF_TARGET)
|
|
|
|
|
2021-07-09 04:04:15 +00:00
|
|
|
idf_component_register(
|
|
|
|
INCLUDE_DIRS include
|
2021-09-02 13:25:34 +00:00
|
|
|
REQUIRES esp_phy
|
2021-07-09 04:04:15 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
if(CONFIG_IEEE802154_ENABLED)
|
2021-09-02 13:25:34 +00:00
|
|
|
idf_component_get_property(esp_phy_lib esp_phy COMPONENT_LIB)
|
2021-07-09 04:04:15 +00:00
|
|
|
if(CONFIG_IEEE802154_LIB_FROM_INTERNAL_SRC)
|
|
|
|
idf_component_get_property(ieee802154_lib ieee802154_driver COMPONENT_LIB)
|
2021-09-02 13:25:34 +00:00
|
|
|
target_link_libraries(${COMPONENT_LIB} INTERFACE $<TARGET_FILE:${ieee802154_lib}> libphy.a libbtbb.a
|
|
|
|
$<TARGET_FILE:${esp_phy_lib}>)
|
2021-07-09 04:04:15 +00:00
|
|
|
else()
|
2021-09-02 13:25:34 +00:00
|
|
|
target_link_libraries(${COMPONENT_LIB} INTERFACE "-L ${CMAKE_CURRENT_SOURCE_DIR}/lib/${idf_target}")
|
|
|
|
target_link_libraries(${COMPONENT_LIB} INTERFACE $<TARGET_FILE:${esp_phy_lib}> lib802154.a libphy.a libbtbb.a
|
|
|
|
$<TARGET_FILE:${esp_phy_lib}>)
|
2021-07-09 04:04:15 +00:00
|
|
|
endif()
|
|
|
|
endif()
|