Mercurial > hg > early-roguelike
comparison arogue5/mdport.c @ 197:61d1c9ac9be7
Advanced Rogue 5: rearrange some of mdport.c.
process.h is now included in the proper place for compiling with MSVC.
md_sleep() has been removed. If it were used anywhere, it could have
been fixed by replacing _sleep() with Sleep().
author | John "Elwin" Edwards |
---|---|
date | Tue, 11 Aug 2015 15:29:31 -0400 |
parents | 80a590e67206 |
children | 56e748983fa8 |
comparison
equal
deleted
inserted
replaced
196:80a590e67206 | 197:61d1c9ac9be7 |
---|---|
34 #endif | 34 #endif |
35 | 35 |
36 #if defined(_WIN32) | 36 #if defined(_WIN32) |
37 #include <Windows.h> | 37 #include <Windows.h> |
38 #include <Lmcons.h> | 38 #include <Lmcons.h> |
39 #include <process.h> | |
40 #include <shlobj.h> | 39 #include <shlobj.h> |
41 #include <sys/types.h> | 40 #include <sys/types.h> |
42 #undef MOUSE_MOVED | 41 #undef MOUSE_MOVED |
43 #elif defined(__DJGPP__) | 42 #elif defined(__DJGPP__) |
44 #include <process.h> | 43 #include <process.h> |
65 | 64 |
66 #if defined(HAVE_TERM_H) | 65 #if defined(HAVE_TERM_H) |
67 #include <term.h> | 66 #include <term.h> |
68 #elif defined(HAVE_NCURSES_TERM_H) | 67 #elif defined(HAVE_NCURSES_TERM_H) |
69 #include <ncurses/term.h> | 68 #include <ncurses/term.h> |
69 #endif | |
70 | |
71 #if defined(_WIN32) | |
72 #include <process.h> | |
70 #endif | 73 #endif |
71 | 74 |
72 #include <stdio.h> | 75 #include <stdio.h> |
73 #include <fcntl.h> | 76 #include <fcntl.h> |
74 #include <limits.h> | 77 #include <limits.h> |
327 homedir[len] = slash; | 330 homedir[len] = slash; |
328 homedir[len+1] = 0; | 331 homedir[len+1] = 0; |
329 } | 332 } |
330 | 333 |
331 return(homedir); | 334 return(homedir); |
332 } | |
333 | |
334 int | |
335 md_sleep(int s) | |
336 { | |
337 #ifdef _WIN32 | |
338 _sleep(s); | |
339 #else | |
340 sleep(s); | |
341 #endif | |
342 } | 335 } |
343 | 336 |
344 char * | 337 char * |
345 md_getshell() | 338 md_getshell() |
346 { | 339 { |