Mingw needs to use Sleep vs sleep (also seconds go to ms)

This commit is contained in:
Cary R 2012-06-07 09:59:54 -07:00
parent c46823e280
commit f36faa8ab3
2 changed files with 11 additions and 3 deletions

View File

@ -1,5 +1,5 @@
const char COPYRIGHT[] = const char COPYRIGHT[] =
"Copyright (c) 1998-2011 Stephen Williams (steve@icarus.com)"; "Copyright (c) 1998-2012 Stephen Williams (steve@icarus.com)";
/* /*
* This source code is free software; you can redistribute it * This source code is free software; you can redistribute it
@ -788,7 +788,11 @@ int main(int argc, char*argv[])
fprintf( stderr, "Waiting for debugger...\n"); fprintf( stderr, "Waiting for debugger...\n");
bool debugger_release = false; bool debugger_release = false;
while( !debugger_release ) { while( !debugger_release ) {
#if defined(__MINGW32__)
Sleep(1000);
#else
sleep(1); sleep(1);
#endif
} }
} }
library_suff.push_back(strdup(".v")); library_suff.push_back(strdup(".v"));

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2001-2011 Stephen Williams (steve@icarus.com) * Copyright (c) 2001-2012 Stephen Williams (steve@icarus.com)
* *
* This source code is free software; you can redistribute it * This source code is free software; you can redistribute it
* and/or modify it in source code form under the terms of the GNU * and/or modify it in source code form under the terms of the GNU
@ -289,7 +289,11 @@ int main(int argc, char*argv[])
fprintf( stderr, "Waiting for debugger...\n"); fprintf( stderr, "Waiting for debugger...\n");
bool debugger_release = false; bool debugger_release = false;
while( !debugger_release ) { while( !debugger_release ) {
#if defined(__MINGW32__)
Sleep(1000);
#else
sleep(1); sleep(1);
#endif
} }
} }
@ -353,7 +357,7 @@ int main(int argc, char*argv[])
if (version_flag) { if (version_flag) {
fprintf(stderr, "Icarus Verilog runtime version " VERSION " (" fprintf(stderr, "Icarus Verilog runtime version " VERSION " ("
VERSION_TAG ")\n\n"); VERSION_TAG ")\n\n");
fprintf(stderr, "Copyright 1998-2010 Stephen Williams\n\n"); fprintf(stderr, "Copyright 1998-2012 Stephen Williams\n\n");
fprintf(stderr, fprintf(stderr,
" This program is free software; you can redistribute it and/or modify\n" " This program is free software; you can redistribute it and/or modify\n"
" it under the terms of the GNU General Public License as published by\n" " it under the terms of the GNU General Public License as published by\n"