mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 18:40:39 -08:00
Fixed configure.ac and headers in nt/inc. Emulated functions not handled yet.
This commit is contained in:
parent
bc9ce0d9c9
commit
9e821c83d3
4 changed files with 44 additions and 13 deletions
|
|
@ -43,8 +43,9 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
|
|||
#undef FD_ZERO
|
||||
#endif
|
||||
|
||||
/* avoid duplicate definition of timeval */
|
||||
#ifdef HAVE_TIMEVAL
|
||||
/* Avoid duplicate definition of timeval. MinGW uses _TIMEVAL_DEFINED
|
||||
in sys/time.h to avoid that. */
|
||||
#if defined (HAVE_TIMEVAL) && defined (_MSC_VER)
|
||||
#define timeval ws_timeval
|
||||
#endif
|
||||
|
||||
|
|
@ -62,7 +63,9 @@ typedef unsigned short uint16_t;
|
|||
#undef MUST_REDEF_SELECT
|
||||
#endif
|
||||
|
||||
/* revert to our version of FD_SET */
|
||||
/* Revert to our version of FD_SET, but not when included from test
|
||||
programs run by configure. */
|
||||
#ifdef EMACS_CONFIG_H
|
||||
#undef FD_SET
|
||||
#undef FD_CLR
|
||||
#undef FD_ISSET
|
||||
|
|
@ -71,8 +74,9 @@ typedef unsigned short uint16_t;
|
|||
/* allow us to provide our own version of fd_set */
|
||||
#define fd_set ws_fd_set
|
||||
#include "w32.h"
|
||||
#endif /* EMACS_CONFIG_H */
|
||||
|
||||
#ifdef HAVE_TIMEVAL
|
||||
#if defined (HAVE_TIMEVAL) && defined (_MSC_VER)
|
||||
#undef timeval
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -6,11 +6,22 @@
|
|||
* have the below stuff.
|
||||
*/
|
||||
|
||||
/* Allow inclusion of sys/time.h and winsock2.h in any order. Needed
|
||||
for running the configure test, which is only relevant to MinGW. */
|
||||
#ifndef _TIMEVAL_DEFINED
|
||||
#define _TIMEVAL_DEFINED
|
||||
struct timeval
|
||||
{
|
||||
long tv_sec; /* seconds */
|
||||
long tv_usec; /* microseconds */
|
||||
};
|
||||
#define timerisset(tvp) ((tvp)->tv_sec || (tvp)->tv_usec)
|
||||
#define timercmp(tvp, uvp, cmp) \
|
||||
(((tvp)->tv_sec != (uvp)->tv_sec) ? \
|
||||
((tvp)->tv_sec cmp (uvp)->tv_sec) : \
|
||||
((tvp)->tv_usec cmp (uvp)->tv_usec))
|
||||
#define timerclear(tvp) (tvp)->tv_sec = (tvp)->tv_usec = 0
|
||||
#endif /* _TIMEVAL_DEFINED */
|
||||
|
||||
struct timezone
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue