428
|
1 /* system description file for cygwin32.
|
|
2 Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
|
558
|
3 Copyright (C) 2001 Ben Wing.
|
428
|
4
|
613
|
5 This file is part of XEmacs.
|
428
|
6
|
613
|
7 XEmacs is free software; you can redistribute it and/or modify
|
428
|
8 it under the terms of the GNU General Public License as published by
|
|
9 the Free Software Foundation; either version 2, or (at your option)
|
|
10 any later version.
|
|
11
|
613
|
12 XEmacs is distributed in the hope that it will be useful,
|
428
|
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
15 GNU General Public License for more details.
|
|
16
|
|
17 You should have received a copy of the GNU General Public License
|
|
18 along with XEmacs; see the file COPYING. If not, write to
|
|
19 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
|
20 Boston, MA 02111-1307, USA. */
|
|
21
|
|
22 /* Building under cygwin
|
|
23 *
|
442
|
24 * The approach I have taken with this port is to use primarily the
|
|
25 * UNIX code base adding stuff that is MS-Windows specific. This works
|
|
26 * quite well, and is in keeping with my perception of the cygwin
|
|
27 * philosophy. Note that if you make changes to this file you do NOT
|
|
28 * want to define WIN32_NATIVE (formerly "WINDOWSNT"), I repeat - do
|
|
29 * not define this, it will break everything horribly. What does get
|
|
30 * defined is HAVE_MS_WINDOWS, but this is done by configure and only
|
|
31 * applies to the window system.
|
428
|
32 *
|
|
33 * When building make sure your HOME path is unix style - i.e. without
|
|
34 * a drive letter.
|
|
35 *
|
|
36 * once you have done this, configure and make.
|
|
37 *
|
|
38 * windows '95 - I haven't tested this under '95, it will probably
|
|
39 * build but I konw there are some limitations with cygwin under 95 so
|
|
40 * YMMV. I build with NT4 SP3.
|
|
41 *
|
|
42 * Andy Piper <andy@xemacs.org> 8/1/98
|
|
43 * http://www.xemacs.freeserve.co.uk/ */
|
|
44
|
442
|
45 /* Identify ourselves */
|
|
46 #define CYGWIN
|
|
47
|
428
|
48 /* cheesy way to determine cygwin version */
|
|
49 #ifndef NOT_C_CODE
|
442
|
50 # include <signal.h>
|
558
|
51 # include <cygwin/version.h>
|
442
|
52
|
558
|
53 void cygwin_win32_to_posix_path_list (const char *, char *);
|
|
54 int cygwin_win32_to_posix_path_list_buf_size (const char *);
|
|
55 void cygwin_posix_to_win32_path_list (const char *, char *);
|
|
56 int cygwin_posix_to_win32_path_list_buf_size (const char *);
|
428
|
57
|
442
|
58 /* Still left out of 1.1! */
|
464
|
59 double logb (double);
|
|
60 int killpg (int pgrp, int sig);
|
442
|
61
|
428
|
62 #endif
|
|
63
|
|
64 #ifndef ORDINARY_LINK
|
|
65 #define ORDINARY_LINK
|
|
66 #endif
|
|
67
|
558
|
68 #define C_SWITCH_SYSTEM -fno-caller-saves
|
428
|
69 #define LIBS_SYSTEM -lwinmm
|
442
|
70 #define WIN32_LEAN_AND_MEAN
|
428
|
71
|
|
72 #define TEXT_START -1
|
|
73 #define TEXT_END -1
|
|
74 #define DATA_END -1
|
|
75 #define HEAP_IN_DATA
|
442
|
76 #define NO_LIM_DATA
|
428
|
77 #define UNEXEC "unexcw.o"
|
|
78
|
|
79 #define BROKEN_SIGIO
|
558
|
80
|
613
|
81 #define CYGWIN_BROKEN_SIGNALS
|
|
82
|
428
|
83 #define strnicmp strncasecmp
|
|
84 #ifndef HAVE_SOCKETS
|
|
85 #define HAVE_SOCKETS
|
|
86 #endif
|
|
87
|
|
88 #undef MAIL_USE_SYSTEM_LOCK
|
|
89
|
442
|
90 /* Do not define LOAD_AVE_TYPE or LOAD_AVE_CVT
|
|
91 since there is no load average available. */
|
428
|
92
|
|
93 /* Define VIRT_ADDR_VARIES if the virtual addresses of
|
|
94 pure and impure space as loaded can vary, and even their
|
|
95 relative order cannot be relied on.
|
|
96
|
|
97 Otherwise Emacs assumes that text space precedes data space,
|
|
98 numerically. */
|
|
99
|
|
100 /* Text does precede data space, but this is never a safe assumption. */
|
|
101 #define VIRT_ADDR_VARIES
|
|
102
|
|
103 /* If you are compiling with a non-C calling convention but need to
|
|
104 declare vararg routines differently, put it here */
|
|
105 #define _VARARGS_ __cdecl
|
|
106
|
|
107 /* If you are providing a function to something that will call the
|
|
108 function back (like a signal handler and signal, or main) its calling
|
|
109 convention must be whatever standard the libraries expect */
|
|
110 #define _CALLBACK_ __cdecl
|
|
111
|
|
112 /* SYSTEM_TYPE should indicate the kind of system you are using.
|
|
113 It sets the Lisp variable system-type. */
|
|
114
|
|
115 #define SYSTEM_TYPE "cygwin32"
|
|
116
|
|
117 #define NO_MATHERR
|
|
118
|
|
119 /* define MAIL_USE_FLOCK if the mailer uses flock
|
|
120 to interlock access to /usr/spool/mail/$USER.
|
|
121 The alternative is that a lock file named
|
|
122 /usr/spool/mail/$USER.lock. */
|
|
123
|
|
124 /* If the character used to separate elements of the executable path
|
|
125 is not ':', #define this to be the appropriate character constant. */
|
|
126 #define SEPCHAR ':'
|
|
127
|
|
128 /* ============================================================ */
|
|
129
|
|
130 /* Here, add any special hacks needed
|
|
131 to make Emacs work on this system. For example,
|
|
132 you might define certain system call names that don't
|
|
133 exist on your system, or that do different things on
|
|
134 your system and must be used only through an encapsulation
|
|
135 (Which you should place, by convention, in sysdep.c). */
|
|
136
|
|
137 /* Define this to be the separator between path elements */
|
|
138 /* #define DIRECTORY_SEP XINT (Vdirectory_sep_char) */
|
|
139
|
|
140 /* Define this to be the separator between devices and paths */
|
|
141 #define DEVICE_SEP ':'
|
|
142
|
|
143 /* We'll support either convention on NT. */
|
|
144 #define IS_DIRECTORY_SEP(_c_) ((_c_) == '/' || (_c_) == '\\')
|
|
145 #define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_) || IS_DEVICE_SEP (_c_))
|
|
146 #define EXEC_SUFFIXES ".exe:.com:.bat:.cmd:"
|
|
147
|
|
148 /* We need a little extra space, see ../../lisp/loadup.el */
|
|
149 #define SYSTEM_PURESIZE_EXTRA 15000
|
|
150
|
|
151 #define CYGWIN_CONV_PATH(src, dst) \
|
442
|
152 dst = alloca (cygwin_win32_to_posix_path_list_buf_size(src)); \
|
|
153 cygwin_win32_to_posix_path_list(src, dst)
|
593
|
154 /* !!#### more mule bogosity */
|
428
|
155 #define CYGWIN_WIN32_PATH(src, dst) \
|
593
|
156 dst = (Extbyte *) alloca (cygwin_posix_to_win32_path_list_buf_size(src)); \
|
442
|
157 cygwin_posix_to_win32_path_list(src, dst)
|