diff --git a/src/api/api_lib.c b/src/api/api_lib.c index c4c2c8a2..0762afc2 100644 --- a/src/api/api_lib.c +++ b/src/api/api_lib.c @@ -40,6 +40,7 @@ #include "lwip/tcpip.h" #include "lwip/memp.h" +#if !NO_SYS struct netbuf *netbuf_new(void) @@ -689,3 +690,4 @@ netconn_err(struct netconn *conn) return conn->err; } +#endif /* !NO_SYS */ diff --git a/src/api/api_msg.c b/src/api/api_msg.c index 077ed3a9..81f5e927 100644 --- a/src/api/api_msg.c +++ b/src/api/api_msg.c @@ -38,6 +38,8 @@ #include "lwip/tcpip.h" #include "lwip/igmp.h" +#if !NO_SYS + #if LWIP_RAW static u8_t recv_raw(void *arg, struct raw_pcb *pcb, struct pbuf *p, @@ -746,3 +748,5 @@ do_join_leave_group(struct api_msg_msg *msg) sys_mbox_post(msg->conn->mbox, NULL); } #endif /* LWIP_IGMP */ + +#endif /* !NO_SYS */ diff --git a/src/api/sockets.c b/src/api/sockets.c index 06a78d3d..1edf50f8 100644 --- a/src/api/sockets.c +++ b/src/api/sockets.c @@ -44,6 +44,8 @@ #include "lwip/inet.h" #include "lwip/tcp.h" +#if !NO_SYS + #define NUM_SOCKETS MEMP_NUM_NETCONN struct lwip_socket { @@ -1432,3 +1434,4 @@ int lwip_ioctl(int s, long cmd, void *argp) } } +#endif /* !NO_SYS */ diff --git a/src/api/tcpip.c b/src/api/tcpip.c index 94f82dd9..d0f07fbf 100644 --- a/src/api/tcpip.c +++ b/src/api/tcpip.c @@ -47,6 +47,8 @@ #include "lwip/tcpip.h" #include "lwip/igmp.h" +#if !NO_SYS + static void (* tcpip_init_done)(void *arg) = NULL; static void *tcpip_init_done_arg = NULL; static sys_mbox_t mbox = SYS_MBOX_NULL; @@ -368,3 +370,4 @@ tcpip_init(void (* initfunc)(void *), void *arg) sys_thread_new(tcpip_thread, NULL, TCPIP_THREAD_PRIO); } +#endif /* !NO_SYS */