2022-02-18 16:07:10 +08:00
|
|
|
#pragma once
|
|
|
|
|
2022-11-06 09:03:33 +08:00
|
|
|
#if defined(MG_ENABLE_LWIP) && MG_ENABLE_LWIP
|
2023-03-21 23:09:00 +08:00
|
|
|
|
|
|
|
#if defined(__GNUC__) && !defined(__ARMCC_VERSION)
|
2022-02-18 16:07:10 +08:00
|
|
|
#include <sys/stat.h>
|
2023-03-21 23:09:00 +08:00
|
|
|
#endif
|
|
|
|
|
|
|
|
struct timeval;
|
|
|
|
|
|
|
|
#include <lwip/sockets.h>
|
|
|
|
|
|
|
|
#if !LWIP_TIMEVAL_PRIVATE
|
|
|
|
#if defined(__GNUC__) && !defined(__ARMCC_VERSION) // armclang sets both
|
2022-02-18 16:07:10 +08:00
|
|
|
#include <sys/time.h>
|
|
|
|
#else
|
|
|
|
struct timeval {
|
|
|
|
time_t tv_sec;
|
|
|
|
long tv_usec;
|
|
|
|
};
|
|
|
|
#endif
|
2023-03-21 23:09:00 +08:00
|
|
|
#endif
|
2022-02-18 16:07:10 +08:00
|
|
|
|
|
|
|
#if LWIP_SOCKET != 1
|
|
|
|
// Sockets support disabled in LWIP by default
|
|
|
|
#error Set LWIP_SOCKET variable to 1 (in lwipopts.h)
|
|
|
|
#endif
|
|
|
|
#endif
|