summaryrefslogtreecommitdiff
path: root/libgfortran/intrinsics/sleep.c
diff options
context:
space:
mode:
authorfxcoudert <fxcoudert@138bc75d-0d04-0410-961f-82ee72b054a4>2005-09-24 08:55:37 +0000
committerfxcoudert <fxcoudert@138bc75d-0d04-0410-961f-82ee72b054a4>2005-09-24 08:55:37 +0000
commit8420f71f8ac1382f9da0766fc7b337734764f164 (patch)
treed934bead1e7178d9c72d114717c4697185a8b590 /libgfortran/intrinsics/sleep.c
parent17f41f1a85a2efa6cd89a601ca5f014e20840f74 (diff)
downloadgcc-8420f71f8ac1382f9da0766fc7b337734764f164.tar.gz
PR libfortran/23802
* intrinsics/sleep.c: Add correct sleep macro for MinGW. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@104599 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libgfortran/intrinsics/sleep.c')
-rw-r--r--libgfortran/intrinsics/sleep.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/libgfortran/intrinsics/sleep.c b/libgfortran/intrinsics/sleep.c
index 05edc3f54b7..a9f579cb69d 100644
--- a/libgfortran/intrinsics/sleep.c
+++ b/libgfortran/intrinsics/sleep.c
@@ -39,6 +39,13 @@ Boston, MA 02110-1301, USA. */
#include <unistd.h>
#endif
+#ifdef __MINGW32__
+# include <windows.h>
+# undef sleep
+# define sleep(x) Sleep(1000*(x))
+# define HAVE_SLEEP
+#endif
+
/* SUBROUTINE SLEEP(SECONDS)
INTEGER, INTENT(IN) :: SECONDS