1# SPDX-License-Identifier: Apache-2.0 2 3zephyr_library() 4 5zephyr_library_sources_ifdef(CONFIG_NET_LOOPBACK loopback.c) 6zephyr_library_sources_ifdef(CONFIG_NET_CANBUS canbus.c) 7 8if(CONFIG_NET_NATIVE) 9zephyr_library_sources_ifdef(CONFIG_SLIP slip.c) 10zephyr_library_sources_ifdef(CONFIG_NET_PPP ppp.c) 11endif() 12 13if(CONFIG_NET_NATIVE_OFFLOADED_SOCKETS) 14 zephyr_library_include_directories( 15 ${ZEPHYR_BASE}/subsys/net/lib/sockets 16 ) 17 zephyr_library_sources(nsos_errno.c) 18 zephyr_library_sources(nsos_fcntl.c) 19 zephyr_library_sources(nsos_netdb.c) 20 zephyr_library_sources(nsos_sockets.c) 21 target_compile_options(native_simulator BEFORE INTERFACE 22 -I${BOARD_DIR} 23 -DNSOS_EPOLL_WAIT_INTERVAL=${CONFIG_NET_NATIVE_OFFLOADED_SOCKETS_EPOLL_WAIT_INTERVAL} 24 ) 25 target_sources(native_simulator INTERFACE nsos_adapt.c) 26 target_sources(native_simulator INTERFACE nsos_errno.c) 27 target_sources(native_simulator INTERFACE nsos_fcntl.c) 28 target_sources(native_simulator INTERFACE nsos_netdb.c) 29endif() 30