Mercurial > emacs
annotate nt/makefile.def @ 11945:d8fba932b289
(compilation-error-regexp-alist): In "IBM C/C++ Tools" regexp, disallow
leading spaces and disallow whitespace chars within the file name.
author | Roland McGrath <roland@gnu.org> |
---|---|
date | Fri, 26 May 1995 16:24:57 +0000 |
parents | 51cb98d13316 |
children | 268be0c80ca2 |
rev | line source |
---|---|
11766 | 1 # |
2 # Makefile definition file for building GNU Emacs on Windows NT | |
3 # | |
4 # GNU Emacs is free software; you can redistribute it and/or modify | |
5 # it under the terms of the GNU General Public License as published by | |
6 # the Free Software Foundation; either version 2, or (at your option) | |
7 # any later version. | |
8 # | |
9 # GNU Emacs is distributed in the hope that it will be useful, | |
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 # GNU General Public License for more details. | |
13 # | |
14 # You should have received a copy of the GNU General Public License | |
15 # along with GNU Emacs; see the file COPYING. If not, write to | |
16 # the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ | |
17 # | |
18 # Geoff Voelker (voelker@cs.washington.edu) 9-6-94 | |
19 | |
20 # | |
21 # BEGIN CONFIGURATION | |
22 # | |
23 | |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
24 # Set INSTALL_DIR to be the directory into which you want emacs installed. |
11766 | 25 # |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
26 !ifndef INSTALL_DIR |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
27 INSTALL_DIR = C:\emacs |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
28 !endif |
11766 | 29 |
30 # | |
31 # END CONFIGURATION | |
32 # | |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
33 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
34 # Check that the INCLUDE and LIB environment variables are set. |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
35 # |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
36 !ifndef INCLUDE |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
37 !error The INCLUDE environment variable needs to be set. |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
38 !endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
39 !ifndef LIB |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
40 !error The LIB environment variable needs to be set. |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
41 !endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
42 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
43 # Determine the architecture we're running on. |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
44 # Define ARCH for our purposes; |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
45 # Define CPU for use by ntwin32.mak; |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
46 # Define CONFIG_H to the appropriate config.h for the system; |
11766 | 47 # |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
48 !ifdef PROCESSOR_ARCHITECTURE |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
49 # We're on Windows NT |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
50 CPU = $(PROCESSOR_ARCHITECTURE) |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
51 CONFIG_H = config.nt |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
52 OS_TYPE = winnt |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
53 ! if "$(PROCESSOR_ARCHITECTURE)" == "x86" |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
54 ARCH = i386 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
55 CPU = i386 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
56 ! else |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
57 ! if "$(PROCESSOR_ARCHITECTURE)" == "MIPS" |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
58 ARCH = mips |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
59 ! else |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
60 ! if "$(PROCESSOR_ARCHITECTURE)" == "ALPHA" |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
61 ARCH = alpha |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
62 ! else |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
63 ! if "$(PROCESSOR_ARCHITECTURE)" == "PPC" |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
64 ARCH = ppc |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
65 ! else |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
66 !error Unknown architecture type "$(PROCESSOR_ARCHITECTURE)" |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
67 ! endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
68 ! endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
69 ! endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
70 ! endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
71 !else |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
72 # We're on Windows 95 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
73 ARCH = i386 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
74 CPU = i386 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
75 CONFIG_H = config.w95 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
76 OS_TYPE = win95 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
77 !endif |
11766 | 78 |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
79 # Include ntwin32.mak. So far, this file seems to be supported by every |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
80 # Microsoft compiler on NT and Win95 and properly defines the executable |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
81 # names and libraries necessary to build Emacs. I do not have access |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
82 # to any other vendor compilers, so I do not know if they supply this |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
83 # file, too. For now I'll assume that they do. |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
84 # |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
85 !include <ntwin32.mak> |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
86 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
87 # Using cvtres is necessary on NT 3.10 and doesn't hurt on later platforms. |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
88 CVTRES = cvtres.exe |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
89 AR = $(implib) |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
90 # The assignment $(CC) = $(cc) fails even though variables are case sensitive. |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
91 LINK_TMP = $(link) |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
92 LINK = $(LINK_TMP) |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
93 CC_TMP = $(cc) |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
94 CC = $(CC_TMP) |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
95 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
96 # advapi32.lib is left off of $(baselibs) on NT 3.10 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
97 !if "$(baselibs)" == "kernel32.lib " |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
98 ADVAPI32 = advapi32.lib |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
99 !else |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
100 ADVAPI32 = |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
101 !endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
102 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
103 # Older ntwin32.mak files do not define libc; do it for them. |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
104 !ifndef libc |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
105 libc = libc.lib |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
106 !endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
107 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
108 # The base libraries for compiling Emacs on NT. With MSVC, this should |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
109 # include oldnames.lib. |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
110 BASE_LIBS = $(libc) $(baselibs) |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
111 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
112 # We want any debugging info in the executable. |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
113 !if "$(LINK)" == "link32" |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
114 SYS_LDFLAGS = |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
115 !else |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
116 SYS_LDFLAGS = -pdb:none -release -incremental:no |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
117 !endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
118 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
119 INC = -I. |
11766 | 120 CFLAGS = -nologo $(INC) $(ARCH_CFLAGS) $(LOCAL_FLAGS) -DWIN32_LEAN_AND_MEAN -D$(ARCH) |
121 | |
122 OBJDIR = obj | |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
123 $(OBJDIR):; -mkdir $(OBJDIR) |
11766 | 124 BLD = $(OBJDIR)\$(ARCH) |
125 $(BLD): $(OBJDIR) | |
126 -mkdir $(BLD) | |
127 | |
128 CP = copy | |
129 CP_DIR = xcopy /fried | |
130 | |
131 # This is completely braindamaged, but it's the only routine known to be there | |
132 DEL_TREE = echo y | rmdir /s | |
133 | |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
134 !if "$(ARCH)" == "i386" |
11766 | 135 ARCH_CFLAGS = -nologo -D_X86_=1 -c -Zel -W2 -H63 -G3d -Zi -Od |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
136 ARCH_LDFLAGS = -align:0x1000 $(SYS_LDFLAGS) |
11766 | 137 |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
138 !else |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
139 !if "$(ARCH)" == "mips" |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
140 ARCH_CFLAGS = -D_MIPS_=1 -c -W2 -Zi -Od -Gt0 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
141 ARCH_LDFLAGS = -align:0x1000 $(SYS_LDFLAGS) |
11766 | 142 |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
143 !else |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
144 !if "$(ARCH)" == "alpha" |
11766 | 145 ARCH_CFLAGS = -D_ALPHA_=1 -c -Ze -Zi -W2 -D__stdcall= -D__cdecl= |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
146 ARCH_LDFLAGS = -align:0x2000 $(SYS_LDFLAGS) |
11766 | 147 |
11937
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
148 !else |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
149 !if "$(ARCH)" == "ppc" |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
150 # These flags are a guess...if they don't work, please send me mail. |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
151 ARCH_CFLAGS = -D_PPC_=1 -c -Ze -Zi -W2 -Od |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
152 ARCH_LDFLAGS = -align:0x1000 $(SYS_LDFLAGS) |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
153 |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
154 !else |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
155 !ERROR Unknown architecture type "$(ARCH)". |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
156 !endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
157 !endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
158 !endif |
51cb98d13316
(ARCH): New definition.
Geoff Voelker <voelker@cs.washington.edu>
parents:
11766
diff
changeset
|
159 !endif |