1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-20 19:50:24 +02:00

Made `usleep()' avalable on MinGW.

This commit is contained in:
Marius Vollmer 2001-11-02 00:16:57 +00:00
parent 4f68365d03
commit ed618cc9c1

View file

@ -81,6 +81,7 @@ int usleep ();
#define alarm(sec) (0)
/* This weird comma expression is because Sleep is void under Windows. */
#define sleep(sec) (Sleep ((sec) * 1000), 0)
#define usleep(usec) (Sleep ((usec) / 1000), 0)
#define kill(pid, sig) raise (sig)
#endif
@ -534,7 +535,7 @@ SCM_DEFINE (scm_sleep, "sleep", 1, 0, 0,
}
#undef FUNC_NAME
#if defined(USE_THREADS) || defined(HAVE_USLEEP)
#if defined(USE_THREADS) || defined(HAVE_USLEEP) || defined(__MINGW32__)
SCM_DEFINE (scm_usleep, "usleep", 1, 0, 0,
(SCM i),
"Sleep for I microseconds. @code{usleep} is not available on\n"
@ -562,7 +563,7 @@ SCM_DEFINE (scm_usleep, "usleep", 1, 0, 0,
#endif
}
#undef FUNC_NAME
#endif /* GUILE_ISELECT || HAVE_USLEEP */
#endif /* USE_THREADS || HAVE_USLEEP || __MINGW32__ */
SCM_DEFINE (scm_raise, "raise", 1, 0, 0,
(SCM sig),