comparison src/s/mingw32.h @ 404:2f8bb876ab1d r21-2-32

Import from CVS: tag r21-2-32
author cvs
date Mon, 13 Aug 2007 11:16:07 +0200
parents a86b2b5e0111
children 501cfd01ee6d
comparison
equal deleted inserted replaced
403:9f011ab08d48 404:2f8bb876ab1d
25 #endif 25 #endif
26 26
27 #ifndef DOS_NT 27 #ifndef DOS_NT
28 #define DOS_NT /* MSDOS or WINDOWSNT */ 28 #define DOS_NT /* MSDOS or WINDOWSNT */
29 #endif 29 #endif
30
31 #define PBS_SMOOTH 0x01
32 30
33 #ifdef HAVE_MS_WINDOWS 31 #ifdef HAVE_MS_WINDOWS
34 #define HAVE_NTGUI 32 #define HAVE_NTGUI
35 #define HAVE_FACES 33 #define HAVE_FACES
36 #endif 34 #endif
49 #define UNEXEC "unexcw.o" 47 #define UNEXEC "unexcw.o"
50 48
51 #define TIME_ONESHOT 0 49 #define TIME_ONESHOT 0
52 #define TIME_PERIODIC 1 50 #define TIME_PERIODIC 1
53 #define LOCALE_USE_CP_ACP 0x40000000 51 #define LOCALE_USE_CP_ACP 0x40000000
54 #define SHGFI_EXETYPE 0x2000
55 #define NSIG 23 52 #define NSIG 23
56 53
57 #ifndef SPI_GETWHEELSCROLLLINES 54 #ifndef SPI_GETWHEELSCROLLLINES
58 #define SPI_GETWHEELSCROLLLINES 104 55 #define SPI_GETWHEELSCROLLLINES 104
59 #endif 56 #endif
61 #define WHEEL_PAGESCROLL (UINT_MAX) 58 #define WHEEL_PAGESCROLL (UINT_MAX)
62 #endif 59 #endif
63 #ifndef WHEEL_DELTA 60 #ifndef WHEEL_DELTA
64 #define WHEEL_DELTA 120 61 #define WHEEL_DELTA 120
65 #endif 62 #endif
63
64 /* this is necessary to get the TCS_* definitions in <commctrl.h> */
65 #define _WIN32_IE 0x0400
66
66 #ifndef WM_MOUSEWHEEL 67 #ifndef WM_MOUSEWHEEL
67 #define WM_MOUSEWHEEL 0x20A 68 #define WM_MOUSEWHEEL 0x20A
69 #endif
70 #ifndef TCS_BOTTOM
71 #define TCS_BOTTOM 0x0002
72 #endif
73 #ifndef TCS_VERTICAL
74 #define TCS_VERTICAL 0x0080
75 #endif
76 #ifndef PHYSICALWIDTH
77 #define PHYSICALWIDTH 110
78 #endif
79 #ifndef PHYSICALHEIGHT
80 #define PHYSICALHEIGHT 111
81 #endif
82 #ifndef PHYSICALOFFSETX
83 #define PHYSICALOFFSETX 112
84 #endif
85 #ifndef PHYSICALOFFSETY
86 #define PHYSICALOFFSETY 113
87 #endif
88 #ifndef PBS_SMOOTH
89 #define PBS_SMOOTH 0x01
68 #endif 90 #endif
69 91
70 /* translate NT world unexec stuff to our a.out definitions */ 92 /* translate NT world unexec stuff to our a.out definitions */
71 93
72 #define strnicmp strncasecmp 94 #define strnicmp strncasecmp
167 #undef mkdir 189 #undef mkdir
168 #ifdef HAVE_CYGWIN_VERSION_H 190 #ifdef HAVE_CYGWIN_VERSION_H
169 #include <cygwin/version.h> 191 #include <cygwin/version.h>
170 #endif 192 #endif
171 193
172 typedef unsigned int MMRESULT;
173 typedef struct timecaps_tag {
174 unsigned int wPeriodMin;
175 unsigned int wPeriodMax;
176 } TIMECAPS;
177
178 /* IO calls that are emulated or shadowed */ 194 /* IO calls that are emulated or shadowed */
179 #define pipe sys_pipe 195 #define pipe sys_pipe
180 int sys_pipe (int * phandles); 196 int sys_pipe (int * phandles);
181 197
182 #ifndef HAVE_X_WINDOWS 198 #ifndef HAVE_X_WINDOWS
196 int kill (int pid, int sig); 212 int kill (int pid, int sig);
197 213
198 /* map to MSVC names */ 214 /* map to MSVC names */
199 #define popen _popen 215 #define popen _popen
200 #define pclose _pclose 216 #define pclose _pclose
201
202 typedef int uid_t;
203 typedef int gid_t;
204 typedef int pid_t;
205 typedef int ssize_t;
206 217
207 /* Encapsulation of system calls */ 218 /* Encapsulation of system calls */
208 #ifndef DONT_ENCAPSULATE 219 #ifndef DONT_ENCAPSULATE
209 #define getpid sys_getpid 220 #define getpid sys_getpid
210 pid_t getpid (void); 221 pid_t getpid (void);
228 struct passwd *getpwnam (const char *name); 239 struct passwd *getpwnam (const char *name);
229 uid_t getuid (void); 240 uid_t getuid (void);
230 uid_t geteuid (void); 241 uid_t geteuid (void);
231 gid_t getgid (void); 242 gid_t getgid (void);
232 gid_t getegid (void); 243 gid_t getegid (void);
244
245 #if CYGWIN_VERSION_DLL_MAJOR <= 21
246 #define _ftime ftime
233 #define _timeb timeb 247 #define _timeb timeb
248 #endif
234 249
235 /* Stuff that gets set wrongly or otherwise */ 250 /* Stuff that gets set wrongly or otherwise */
236 #define HAVE_SETITIMER 251 #define HAVE_SETITIMER
237 #define HAVE_GETTIMEOFDAY 252 #define HAVE_GETTIMEOFDAY
238 #define HAVE_SELECT 253 #define HAVE_SELECT
239 /*#define HAVE_STRUCT_UTIMBUF*/ 254 /*#define HAVE_STRUCT_UTIMBUF*/
255 #ifndef HAVE_H_ERRNO
256 #define HAVE_H_ERRNO
257 #endif
258 #ifndef HAVE_TZNAME
259 #define HAVE_TZNAME
260 #endif
240 261
241 #undef GETTIMEOFDAY_ONE_ARGUMENT 262 #undef GETTIMEOFDAY_ONE_ARGUMENT
242 #undef HAVE_SYS_WAIT_H 263 #undef HAVE_SYS_WAIT_H
243 #undef HAVE_TERMIOS 264 #undef HAVE_TERMIOS
244 #undef SYSV_SYSTEM_DIR 265 #undef SYSV_SYSTEM_DIR