Skip to content

Commit 5b5e7b0

Browse files
committed
Fix WiFi link error for as default network interface
This fixes WiFi doesn't get linked in when configued as default network interface.
1 parent af80d11 commit 5b5e7b0

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

connectivity/netsocket/CMakeLists.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,12 @@ if("MBED_CONF_TARGET_NETWORK_DEFAULT_INTERFACE_TYPE=MESH" IN_LIST MBED_CONFIG_DE
7474
target_link_libraries(mbed-netsocket-api PUBLIC mbed-nanostack-mbed_mesh_api)
7575
endif()
7676

77+
# Similarly if wifi networking is used bring in that library
78+
if("MBED_CONF_TARGET_NETWORK_DEFAULT_INTERFACE_TYPE=WIFI" IN_LIST MBED_CONFIG_DEFINITIONS)
79+
if(TARGET mbed-wifi)
80+
target_link_libraries(mbed-netsocket-api PUBLIC mbed-wifi)
81+
endif()
82+
endif()
7783

7884
if("DEVICE_EMAC=1" IN_LIST MBED_TARGET_DEFINITIONS)
7985
target_link_libraries(mbed-netsocket-api

0 commit comments

Comments
 (0)