7
|
1 # Makefile for Borland C++ 3.1 or 4.0 to compile a 16 bit version of Vim.
|
|
2 #
|
|
3 # There are compilation options at the end of this file.
|
|
4 #
|
|
5 # Command line variables:
|
|
6 # BOR path to root of Borland C (E:\BORLANDC)
|
|
7 # DEBUG set to "yes" for debugging (no)
|
|
8 # SPAWNO path to the spawno library directory, empty if you do not have
|
|
9 # it; use 8.3 filenames! (C:\CC\SPAWN)
|
|
10
|
|
11 .AUTODEPEND
|
|
12
|
|
13 !ifndef BOR
|
|
14 BOR = E:\BORLANDC
|
|
15 !endif
|
|
16
|
|
17 !if ("$(DEBUG)" == "yes")
|
|
18 DEBUG_FLAG = -v
|
|
19 !else
|
|
20 DEBUG_FLAG =
|
|
21 !endif
|
|
22
|
|
23 CC = $(BOR)\bin\bcc.exe +VIM.CFG
|
|
24 TLINK = $(BOR)\bin\tlink.exe
|
|
25
|
|
26 !ifndef SPAWNO
|
|
27 SPAWNO = C:\CC\SPAWN
|
|
28 !endif
|
|
29
|
|
30 !if ("$(SPAWNO)" == "")
|
|
31 LIBPATH = $(BOR)\LIB
|
|
32 INCLUDEPATH = $(BOR)\INCLUDE
|
|
33 SPAWND =
|
|
34 SPAWNL =
|
|
35 !else
|
|
36 LIBPATH = $(BOR)\LIB;$(SPAWNO)
|
|
37 INCLUDEPATH = $(BOR)\INCLUDE;$(SPAWNO)
|
|
38 SPAWND = ;SPAWNO
|
|
39 SPAWNL = spawnl.lib
|
|
40 !endif
|
|
41
|
|
42
|
|
43 # *Implicit Rules*
|
|
44 #
|
|
45 # use -v for debugging
|
|
46 #
|
|
47 .c.obj:
|
|
48 $(CC) -c $(DEBUG_FLAG) {$< }
|
|
49
|
|
50 # *List Macros*
|
|
51
|
|
52
|
|
53 EXE_dependencies = \
|
|
54 buffer.obj \
|
|
55 charset.obj \
|
|
56 diff.obj \
|
|
57 digraph.obj \
|
|
58 edit.obj \
|
|
59 eval.obj \
|
|
60 ex_cmds.obj \
|
|
61 ex_cmds2.obj \
|
|
62 ex_docmd.obj \
|
|
63 ex_eval.obj \
|
|
64 ex_getln.obj \
|
|
65 fileio.obj \
|
|
66 fold.obj \
|
|
67 getchar.obj \
|
|
68 main.obj \
|
|
69 mark.obj \
|
|
70 memfile.obj \
|
|
71 memline.obj \
|
|
72 menu.obj \
|
|
73 message.obj \
|
|
74 misc1.obj \
|
|
75 misc2.obj \
|
|
76 move.obj \
|
|
77 os_msdos.obj \
|
|
78 normal.obj \
|
|
79 ops.obj \
|
|
80 option.obj \
|
|
81 quickfix.obj \
|
|
82 regexp.obj \
|
|
83 screen.obj \
|
|
84 search.obj \
|
|
85 syntax.obj \
|
|
86 tag.obj \
|
|
87 term.obj \
|
|
88 ui.obj \
|
|
89 undo.obj \
|
|
90 window.obj
|
|
91
|
|
92 all: vim.exe install.exe uninstal.exe xxd/xxd.exe
|
|
93
|
|
94 # *Explicit Rules*
|
|
95
|
|
96 vim.exe: vim.cfg $(EXE_dependencies) version.c
|
|
97 $(CC) $(DEBUG_FLAG) -c version.c
|
|
98 $(TLINK) /x/c/L$(LIBPATH) $(DEBUG_FLAG) @&&|
|
|
99 c0l.obj $(EXE_dependencies) version.obj
|
|
100 vim
|
|
101 # no map file
|
|
102 $(SPAWNL) cl.lib
|
|
103 |
|
|
104
|
|
105 install.exe: dosinst.c
|
|
106 $(CC) -einstall $(DEBUG_FLAG) dosinst.c
|
|
107
|
|
108 uninstal.exe: uninstal.c
|
|
109 $(CC) $(DEBUG_FLAG) uninstal.c
|
|
110
|
|
111 # This may fail for older make versions, building xxd will fail anyway then.
|
|
112 xxd/xxd.exe: xxd/xxd.c
|
|
113 cd xxd
|
|
114 $(MAKE) -f Make_bc3.mak BOR=$(BOR) DEBUG=$(DEBUG)
|
|
115 cd ..
|
|
116
|
|
117 # cleaning up: Delete all generated files
|
|
118 clean:
|
|
119 -del *.obj
|
|
120 -del vim.exe
|
|
121 -del vim.sym
|
|
122 -del install.exe
|
|
123 -del uninstal.exe
|
|
124 -del xxd\*.obj
|
|
125 -del xxd\xxd.exe
|
|
126 -del vim.cfg
|
|
127 -del testdir\*.out
|
|
128
|
|
129 # Individual File Dependencies (incomplete)
|
|
130 ex_docmd.obj: ex_docmd.c ex_cmds.h
|
|
131
|
|
132 ex_eval.obj: ex_eval.c ex_cmds.h
|
|
133
|
|
134 main.obj: main.c globals.h option.h
|
|
135
|
|
136 term.obj: term.c term.h
|
|
137
|
|
138 version.obj: version.c version.h
|
|
139
|
|
140
|
|
141 # Compiler Configuration File
|
|
142 #
|
|
143 # The following compile options can be changed for better machines.
|
|
144 # replace -1- with -2 to produce code for a 80286 or higher
|
|
145 # replace -1- with -3 to produce code for a 80386 or higher
|
|
146 # add -v for source debugging
|
|
147 vim.cfg: Make_bc3.mak
|
|
148 copy &&|
|
|
149 -ml
|
|
150 -1-
|
|
151 -f-
|
|
152 -C
|
|
153 -N
|
|
154 -O
|
|
155 -Z
|
|
156 -k-
|
|
157 -d
|
|
158 -h
|
|
159 -vi-
|
|
160 -H=VIM.SYM
|
|
161 -w-par
|
|
162 -weas
|
|
163 -wpre
|
|
164 -Iproto
|
|
165 -I$(INCLUDEPATH)
|
|
166 -L$(LIBPATH)
|
|
167 -DMSDOS$(SPAWND)
|
|
168 | vim.cfg
|
|
169
|
|
170 test:
|
|
171 cd testdir
|
|
172 $(MAKE) -f Make_dos.mak small
|
|
173 cd ..
|