Mercurial > hg > xemacs-beta
comparison src/s/cygwin32.h @ 410:de805c49cfc1 r21-2-35
Import from CVS: tag r21-2-35
author | cvs |
---|---|
date | Mon, 13 Aug 2007 11:19:21 +0200 |
parents | 501cfd01ee6d |
children | 697ef44129c6 |
comparison
equal
deleted
inserted
replaced
409:301b9ebbdf3b | 410:de805c49cfc1 |
---|---|
18 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | 18 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
19 Boston, MA 02111-1307, USA. */ | 19 Boston, MA 02111-1307, USA. */ |
20 | 20 |
21 /* Building under cygwin | 21 /* Building under cygwin |
22 * | 22 * |
23 * The approach I have taken with this port is to use primarily the UNIX | 23 * The approach I have taken with this port is to use primarily the |
24 * code base adding stuff that is MS-Windows specific. This works quite | 24 * UNIX code base adding stuff that is MS-Windows specific. This works |
25 * well, and is in keeping with my perception of the cygwin philosophy. | 25 * quite well, and is in keeping with my perception of the cygwin |
26 * Note that if you make changes to this file you do NOT want to define | 26 * philosophy. Note that if you make changes to this file you do NOT |
27 * WINDOWSNT, I repeat - do not define this, it will break everything | 27 * want to define WIN32_NATIVE (formerly "WINDOWSNT"), I repeat - do |
28 * horribly. What does get defined is HAVE_MS_WINDOWS, but this is | 28 * not define this, it will break everything horribly. What does get |
29 * done by configure and only applies to the window system. | 29 * defined is HAVE_MS_WINDOWS, but this is done by configure and only |
30 * applies to the window system. | |
30 * | 31 * |
31 * When building make sure your HOME path is unix style - i.e. without | 32 * When building make sure your HOME path is unix style - i.e. without |
32 * a drive letter. | 33 * a drive letter. |
33 * | 34 * |
34 * once you have done this, configure and make. | 35 * once you have done this, configure and make. |
37 * build but I konw there are some limitations with cygwin under 95 so | 38 * build but I konw there are some limitations with cygwin under 95 so |
38 * YMMV. I build with NT4 SP3. | 39 * YMMV. I build with NT4 SP3. |
39 * | 40 * |
40 * Andy Piper <andy@xemacs.org> 8/1/98 | 41 * Andy Piper <andy@xemacs.org> 8/1/98 |
41 * http://www.xemacs.freeserve.co.uk/ */ | 42 * http://www.xemacs.freeserve.co.uk/ */ |
43 | |
44 /* Identify ourselves */ | |
45 #define CYGWIN | |
42 | 46 |
43 /* cheesy way to determine cygwin version */ | 47 /* cheesy way to determine cygwin version */ |
44 #ifndef NOT_C_CODE | 48 #ifndef NOT_C_CODE |
45 # include <signal.h> | 49 # include <signal.h> |
46 # ifdef HAVE_CYGWIN_VERSION_H | 50 # ifdef HAVE_CYGWIN_VERSION_H |
55 # define CYGWIN_VERSION_DLL_MINOR 0 | 59 # define CYGWIN_VERSION_DLL_MINOR 0 |
56 # define BROKEN_CYGWIN | 60 # define BROKEN_CYGWIN |
57 # endif | 61 # endif |
58 # endif | 62 # endif |
59 | 63 |
60 extern void cygwin32_win32_to_posix_path_list(const char*, char*); | 64 void cygwin32_win32_to_posix_path_list (const char*, char*); |
61 extern int cygwin32_win32_to_posix_path_list_buf_size(const char*); | 65 int cygwin32_win32_to_posix_path_list_buf_size (const char*); |
62 extern void cygwin32_posix_to_win32_path_list(const char*, char*); | 66 void cygwin32_posix_to_win32_path_list (const char*, char*); |
63 extern int cygwin32_posix_to_win32_path_list_buf_size(const char*); | 67 int cygwin32_posix_to_win32_path_list_buf_size (const char*); |
64 # if CYGWIN_VERSION_DLL_MAJOR < 20 | 68 # if CYGWIN_VERSION_DLL_MAJOR < 20 |
65 struct timeval; | 69 struct timeval; |
66 struct timezone; | 70 struct timezone; |
67 struct itimerval; | 71 struct itimerval; |
68 struct stat; | 72 struct stat; |
69 extern int gettimeofday(struct timeval *tp, struct timezone *tzp); | 73 int gettimeofday (struct timeval *tp, struct timezone *tzp); |
70 extern int gethostname (char* name, int namelen); | 74 int gethostname (char* name, int namelen); |
71 extern char* mktemp(char *); | 75 char* mktemp (char *); |
72 extern double logb(double); | 76 double logb (double); |
73 extern void sync(); | 77 void sync (void); |
74 extern int ioctl(int, int, ...); | 78 int ioctl (int, int, ...); |
75 /* sys/stat.h */ | 79 /* sys/stat.h */ |
76 extern int lstat(const char *path, struct stat *buf); | 80 int lstat (const char *path, struct stat *buf); |
77 /* unistd.h */ | 81 /* unistd.h */ |
78 extern int readlink(const char *path, void *buf, unsigned int bufsiz); | 82 int readlink (const char *path, void *buf, unsigned int bufsiz); |
79 extern int symlink(const char *name1, const char *name2); | 83 int symlink (const char *name1, const char *name2); |
80 /* sys/time.h */ | 84 /* sys/time.h */ |
81 extern int setitimer(int which, const struct itimerval *value, | 85 int setitimer (int which, const struct itimerval *value, |
82 struct itimerval *ovalue); | 86 struct itimerval *ovalue); |
83 extern int utimes(char *file, struct timeval *tvp); | 87 int utimes (char *file, struct timeval *tvp); |
84 | 88 |
85 extern int srandom( unsigned seed); | 89 int srandom (unsigned seed); |
86 extern long random(); | 90 long random (void); |
87 | 91 |
88 # endif | 92 # endif /* CYGWIN_VERSION_DLL_MAJOR < 20 */ |
89 #endif | 93 |
90 | 94 # if CYGWIN_VERSION_DLL_MAJOR <= 20 |
91 #ifdef HAVE_MS_WINDOWS | 95 char *getpass (const char *prompt); |
92 #define HAVE_NTGUI | 96 double logb (double); |
93 #define HAVE_FACES | 97 # endif /* CYGWIN_VERSION_DLL_MAJOR <= 20 */ |
98 | |
94 #endif | 99 #endif |
95 | 100 |
96 #ifndef ORDINARY_LINK | 101 #ifndef ORDINARY_LINK |
97 #define ORDINARY_LINK | 102 #define ORDINARY_LINK |
98 #endif | 103 #endif |
121 #define strnicmp strncasecmp | 126 #define strnicmp strncasecmp |
122 #ifndef HAVE_SOCKETS | 127 #ifndef HAVE_SOCKETS |
123 #define HAVE_SOCKETS | 128 #define HAVE_SOCKETS |
124 #endif | 129 #endif |
125 #define OBJECTS_SYSTEM ntplay.o | 130 #define OBJECTS_SYSTEM ntplay.o |
126 #define HAVE_NATIVE_SOUND | |
127 | 131 |
128 #undef MAIL_USE_SYSTEM_LOCK | 132 #undef MAIL_USE_SYSTEM_LOCK |
129 #define MAIL_USE_POP | |
130 | 133 |
131 /* Define NO_ARG_ARRAY if you cannot take the address of the first of a | 134 /* Define NO_ARG_ARRAY if you cannot take the address of the first of a |
132 * group of arguments and treat it as an array of the arguments. */ | 135 * group of arguments and treat it as an array of the arguments. */ |
133 | 136 |
134 #define NO_ARG_ARRAY | 137 #define NO_ARG_ARRAY |