Mercurial > vim
annotate src/Make_cyg_ming.mak @ 8861:45fe799c9672 v7.4.1718
commit https://github.com/vim/vim/commit/d56374e25df0b317b01423a01f158157faa647fa
Author: Bram Moolenaar <Bram@vim.org>
Date: Thu Apr 7 22:16:30 2016 +0200
patch 7.4.1718
Problem: Coverity: not using return value of set_ref_in_item().
Solution: Use the return value.
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Thu, 07 Apr 2016 22:30:05 +0200 |
parents | 869727342e43 |
children | c096095ad9fb |
rev | line source |
---|---|
6326 | 1 # Makefile for VIM on Win32 (Cygwin and MinGW) |
2 # | |
3 # This file contains common part for Cygwin and MinGW and it is included | |
4 # from Make_cyg.mak and Make_ming.mak. | |
5 # | |
6 # Info at http://www.mingw.org | |
7 # Alternative x86 and 64-builds: http://mingw-w64.sourceforge.net | |
8 # Also requires GNU make, which you can download from the same sites. | |
9 # Get missing libraries from http://gnuwin32.sf.net. | |
10 # | |
11 # Tested on Win32 NT 4 and Win95. | |
12 # | |
13 # To make everything, just 'make -f Make_ming.mak'. | |
14 # To make just e.g. gvim.exe, 'make -f Make_ming.mak gvim.exe'. | |
15 # After a run, you can 'make -f Make_ming.mak clean' to clean up. | |
16 # | |
17 # NOTE: Sometimes 'GNU Make' will stop after building vimrun.exe -- I think | |
18 # it's just run out of memory or something. Run again, and it will continue | |
19 # with 'xxd'. | |
20 # | |
21 # "make upx" makes *compressed* versions of the 32 bit GUI and console EXEs, | |
22 # using the excellent UPX compressor: | |
23 # http://upx.sourceforge.net/ | |
24 # "make mpress" uses the MPRESS compressor for 32- and 64-bit EXEs: | |
25 # http://www.matcode.com/mpress.htm | |
26 # | |
27 # Maintained by Ron Aaron <ronaharon@yahoo.com> et al. | |
28 # Updated 2014 Oct 13. | |
29 | |
30 #>>>>> choose options: | |
31 # set to yes for a debug build | |
32 DEBUG=no | |
33 # set to SIZE for size, SPEED for speed, MAXSPEED for maximum optimization | |
34 OPTIMIZE=MAXSPEED | |
35 # set to yes to make gvim, no for vim | |
36 GUI=yes | |
37 # set to yes if you want to use DirectWrite (DirectX) | |
38 # MinGW-w64 is needed, and ARCH should be set to i686 or x86-64. | |
39 DIRECTX=no | |
40 # FEATURES=[TINY | SMALL | NORMAL | BIG | HUGE] | |
41 # Set to TINY to make minimal version (few features). | |
7699
854302b82ff9
commit https://github.com/vim/vim/commit/e5f2be61595fbbba77261f3bf1e032fe03a1966d
Christian Brabandt <cb@256bit.org>
parents:
7695
diff
changeset
|
42 FEATURES=HUGE |
6326 | 43 # Set to one of i386, i486, i586, i686 as the minimum target processor. |
44 # For amd64/x64 architecture set ARCH=x86-64 . | |
8120
350f8040bd37
commit https://github.com/vim/vim/commit/223b723be0703137cf6373e23f8ae5c02e92ef82
Christian Brabandt <cb@256bit.org>
parents:
8076
diff
changeset
|
45 ARCH=i686 |
6326 | 46 # Set to yes to cross-compile from unix; no=native Windows (and Cygwin). |
47 CROSS=no | |
48 # Set to path to iconv.h and libiconv.a to enable using 'iconv.dll'. | |
49 #ICONV="." | |
50 ICONV=yes | |
51 GETTEXT=yes | |
52 # Set to yes to include multibyte support. | |
53 MBYTE=yes | |
54 # Set to yes to include IME support. | |
55 IME=yes | |
56 DYNAMIC_IME=yes | |
57 # Set to yes to enable writing a postscript file with :hardcopy. | |
58 POSTSCRIPT=no | |
59 # Set to yes to enable OLE support. | |
60 OLE=no | |
8120
350f8040bd37
commit https://github.com/vim/vim/commit/223b723be0703137cf6373e23f8ae5c02e92ef82
Christian Brabandt <cb@256bit.org>
parents:
8076
diff
changeset
|
61 # Set the default $(WINVER) to make it work with WinXP. |
6326 | 62 ifndef WINVER |
8120
350f8040bd37
commit https://github.com/vim/vim/commit/223b723be0703137cf6373e23f8ae5c02e92ef82
Christian Brabandt <cb@256bit.org>
parents:
8076
diff
changeset
|
63 WINVER = 0x0501 |
6326 | 64 endif |
65 # Set to yes to enable Cscope support. | |
66 CSCOPE=yes | |
7743
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
67 # Set to yes to enable Netbeans support (requires CHANNEL). |
6326 | 68 NETBEANS=$(GUI) |
7743
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
69 # Set to yes to enable inter process communication. |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
70 CHANNEL=$(GUI) |
6326 | 71 |
72 | |
73 # Link against the shared version of libstdc++ by default. Set | |
74 # STATIC_STDCPLUS to "yes" to link against static version instead. | |
75 ifndef STATIC_STDCPLUS | |
76 STATIC_STDCPLUS=no | |
77 endif | |
78 | |
79 # If the user doesn't want gettext, undefine it. | |
80 ifeq (no, $(GETTEXT)) | |
81 GETTEXT= | |
82 endif | |
83 # Added by E.F. Amatria <eferna1@platea.ptic.mec.es> 2001 Feb 23 | |
84 # Uncomment the first line and one of the following three if you want Native Language | |
85 # Support. You'll need gnu_gettext.win32, a MINGW32 Windows PORT of gettext by | |
86 # Franco Bez <franco.bez@gmx.de>. It may be found at | |
87 # http://home.a-city.de/franco.bez/gettext/gettext_win32_en.html | |
88 # Tested with mingw32 with GCC-2.95.2 on Win98 | |
89 # Updated 2001 Jun 9 | |
90 #GETTEXT=c:/gettext.win32.msvcrt | |
91 #STATIC_GETTEXT=USE_STATIC_GETTEXT | |
92 #DYNAMIC_GETTEXT=USE_GETTEXT_DLL | |
93 #DYNAMIC_GETTEXT=USE_SAFE_GETTEXT_DLL | |
94 SAFE_GETTEXT_DLL_OBJ = $(GETTEXT)/src/safe_gettext_dll/safe_gettext_dll.o | |
95 # Alternatively, if you uncomment the two following lines, you get a "safe" version | |
96 # without linking the safe_gettext_dll.o object file. | |
97 #DYNAMIC_GETTEXT=DYNAMIC_GETTEXT | |
98 #GETTEXT_DYNAMIC=gnu_gettext.dll | |
99 INTLPATH=$(GETTEXT)/lib/mingw32 | |
100 INTLLIB=gnu_gettext | |
101 | |
102 # If you are using gettext-0.10.35 from http://sourceforge.net/projects/gettext | |
103 # or gettext-0.10.37 from http://sourceforge.net/projects/mingwrep/ | |
104 # uncomment the following, but I can't build a static version with them, ?-(| | |
105 #GETTEXT=c:/gettext-0.10.37-20010430 | |
106 #STATIC_GETTEXT=USE_STATIC_GETTEXT | |
107 #DYNAMIC_GETTEXT=DYNAMIC_GETTEXT | |
108 #INTLPATH=$(GETTEXT)/lib | |
109 #INTLLIB=intl | |
110 | |
111 # Perl interface: | |
112 # PERL=[Path to Perl directory] (Set inside Make_cyg.mak or Make_ming.mak) | |
113 # DYNAMIC_PERL=yes (to load the Perl DLL dynamically) | |
114 # PERL_VER=[Perl version, eg 56, 58, 510] (default is 56) | |
115 ifdef PERL | |
116 ifndef PERL_VER | |
117 PERL_VER=56 | |
118 endif | |
119 ifndef DYNAMIC_PERL | |
120 DYNAMIC_PERL=yes | |
121 endif | |
122 # on Linux, for cross-compile, it's here: | |
123 #PERLLIB=/home/ron/ActivePerl/lib | |
124 # on NT, it's here: | |
125 PERLEXE=$(PERL)/bin/perl | |
126 PERLLIB=$(PERL)/lib | |
127 PERLLIBS=$(PERLLIB)/Core | |
128 ifeq ($(UNDER_CYGWIN),yes) | |
129 PERLTYPEMAP:=$(shell cygpath -m $(PERLLIB)/ExtUtils/typemap) | |
130 XSUBPPTRY:=$(shell cygpath -m $(PERLLIB)/ExtUtils/xsubpp) | |
131 else | |
132 PERLTYPEMAP=$(PERLLIB)/ExtUtils/typemap | |
133 XSUBPPTRY=$(PERLLIB)/ExtUtils/xsubpp | |
134 endif | |
135 XSUBPP_EXISTS=$(shell $(PERLEXE) -e "print 1 unless -e '$(XSUBPPTRY)'") | |
136 ifeq "$(XSUBPP_EXISTS)" "" | |
6349 | 137 XSUBPP=$(PERLEXE) $(XSUBPPTRY) |
6326 | 138 else |
139 XSUBPP=xsubpp | |
140 endif | |
141 endif | |
142 | |
143 # Lua interface: | |
144 # LUA=[Path to Lua directory] (Set inside Make_cyg.mak or Make_ming.mak) | |
145 # DYNAMIC_LUA=yes (to load the Lua DLL dynamically) | |
146 # LUA_VER=[Lua version, eg 51, 52] (default is 51) | |
147 ifdef LUA | |
148 ifndef DYNAMIC_LUA | |
149 DYNAMIC_LUA=yes | |
150 endif | |
151 | |
152 ifndef LUA_VER | |
153 LUA_VER=51 | |
154 endif | |
155 | |
156 ifeq (no,$(DYNAMIC_LUA)) | |
157 LUA_LIB = -L$(LUA)/lib -llua | |
158 endif | |
159 | |
160 endif | |
161 | |
162 # MzScheme interface: | |
163 # MZSCHEME=[Path to MzScheme directory] (Set inside Make_cyg.mak or Make_ming.mak) | |
164 # DYNAMIC_MZSCHEME=yes (to load the MzScheme DLL dynamically) | |
165 # MZSCHEME_VER=[MzScheme version] (default is 205_000) | |
166 # MZSCHEME_DEBUG=no | |
167 ifdef MZSCHEME | |
168 ifndef DYNAMIC_MZSCHEME | |
169 DYNAMIC_MZSCHEME=yes | |
170 endif | |
171 | |
172 ifndef MZSCHEME_VER | |
173 MZSCHEME_VER=205_000 | |
174 endif | |
175 | |
176 # for version 4.x we need to generate byte-code for Scheme base | |
177 ifndef MZSCHEME_GENERATE_BASE | |
178 MZSCHEME_GENERATE_BASE=no | |
179 endif | |
180 | |
7609
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
181 ifneq ($(wildcard $(MZSCHEME)/lib/msvc/libmzsch$(MZSCHEME_VER).lib),) |
6326 | 182 MZSCHEME_MAIN_LIB=mzsch |
183 else | |
184 MZSCHEME_MAIN_LIB=racket | |
185 endif | |
186 | |
7609
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
187 ifndef MZSCHEME_PRECISE_GC |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
188 MZSCHEME_PRECISE_GC=no |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
189 ifneq ($(wildcard $(MZSCHEME)\lib\lib$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER).dll),) |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
190 ifeq ($(wildcard $(MZSCHEME)\lib\libmzgc$(MZSCHEME_VER).dll),) |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
191 MZSCHEME_PRECISE_GC=yes |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
192 endif |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
193 else |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
194 ifneq ($(wildcard $(MZSCHEME)\lib\msvc\lib$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER).lib),) |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
195 ifeq ($(wildcard $(MZSCHEME)\lib\msvc\libmzgc$(MZSCHEME_VER).lib),) |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
196 MZSCHEME_PRECISE_GC=yes |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
197 endif |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
198 endif |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
199 endif |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
200 endif |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
201 |
6326 | 202 ifeq (no,$(DYNAMIC_MZSCHEME)) |
203 ifeq (yes,$(MZSCHEME_PRECISE_GC)) | |
204 MZSCHEME_LIB=-l$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER) | |
205 else | |
7609
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
206 MZSCHEME_LIB=-l$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER) -lmzgc$(MZSCHEME_VER) |
6326 | 207 endif |
208 # the modern MinGW can dynamically link to dlls directly. | |
209 # point MZSCHEME_DLLS to where you put libmzschXXXXXXX.dll and libgcXXXXXXX.dll | |
210 ifndef MZSCHEME_DLLS | |
211 MZSCHEME_DLLS=$(MZSCHEME) | |
212 endif | |
213 MZSCHEME_LIBDIR=-L$(MZSCHEME_DLLS) -L$(MZSCHEME_DLLS)\lib | |
214 endif | |
215 | |
216 endif | |
217 | |
218 # Python interface: | |
219 # PYTHON=[Path to Python directory] (Set inside Make_cyg.mak or Make_ming.mak) | |
220 # DYNAMIC_PYTHON=yes (to load the Python DLL dynamically) | |
221 # PYTHON_VER=[Python version, eg 22, 23, ..., 27] (default is 22) | |
222 ifdef PYTHON | |
223 ifndef DYNAMIC_PYTHON | |
224 DYNAMIC_PYTHON=yes | |
225 endif | |
226 | |
227 ifndef PYTHON_VER | |
7456
2c5e813e8852
commit https://github.com/vim/vim/commit/3c6f92e52ef15df4aa248ce00eacd65928044210
Christian Brabandt <cb@256bit.org>
parents:
6872
diff
changeset
|
228 PYTHON_VER=27 |
2c5e813e8852
commit https://github.com/vim/vim/commit/3c6f92e52ef15df4aa248ce00eacd65928044210
Christian Brabandt <cb@256bit.org>
parents:
6872
diff
changeset
|
229 endif |
2c5e813e8852
commit https://github.com/vim/vim/commit/3c6f92e52ef15df4aa248ce00eacd65928044210
Christian Brabandt <cb@256bit.org>
parents:
6872
diff
changeset
|
230 ifndef DYNAMIC_PYTHON_DLL |
2c5e813e8852
commit https://github.com/vim/vim/commit/3c6f92e52ef15df4aa248ce00eacd65928044210
Christian Brabandt <cb@256bit.org>
parents:
6872
diff
changeset
|
231 DYNAMIC_PYTHON_DLL=python$(PYTHON_VER).dll |
2c5e813e8852
commit https://github.com/vim/vim/commit/3c6f92e52ef15df4aa248ce00eacd65928044210
Christian Brabandt <cb@256bit.org>
parents:
6872
diff
changeset
|
232 endif |
2c5e813e8852
commit https://github.com/vim/vim/commit/3c6f92e52ef15df4aa248ce00eacd65928044210
Christian Brabandt <cb@256bit.org>
parents:
6872
diff
changeset
|
233 ifdef PYTHON_HOME |
2c5e813e8852
commit https://github.com/vim/vim/commit/3c6f92e52ef15df4aa248ce00eacd65928044210
Christian Brabandt <cb@256bit.org>
parents:
6872
diff
changeset
|
234 PYTHON_HOME_DEF=-DPYTHON_HOME=\"$(PYTHON_HOME)\" |
6326 | 235 endif |
236 | |
237 ifeq (no,$(DYNAMIC_PYTHON)) | |
238 PYTHONLIB=-L$(PYTHON)/libs -lpython$(PYTHON_VER) | |
239 endif | |
240 # my include files are in 'win32inc' on Linux, and 'include' in the standard | |
241 # NT distro (ActiveState) | |
7456
2c5e813e8852
commit https://github.com/vim/vim/commit/3c6f92e52ef15df4aa248ce00eacd65928044210
Christian Brabandt <cb@256bit.org>
parents:
6872
diff
changeset
|
242 ifndef PYTHONINC |
6326 | 243 ifeq ($(CROSS),no) |
244 PYTHONINC=-I $(PYTHON)/include | |
245 else | |
246 PYTHONINC=-I $(PYTHON)/win32inc | |
247 endif | |
248 endif | |
7456
2c5e813e8852
commit https://github.com/vim/vim/commit/3c6f92e52ef15df4aa248ce00eacd65928044210
Christian Brabandt <cb@256bit.org>
parents:
6872
diff
changeset
|
249 endif |
6326 | 250 |
251 # Python3 interface: | |
252 # PYTHON3=[Path to Python3 directory] (Set inside Make_cyg.mak or Make_ming.mak) | |
253 # DYNAMIC_PYTHON3=yes (to load the Python3 DLL dynamically) | |
254 # PYTHON3_VER=[Python3 version, eg 31, 32] (default is 31) | |
255 ifdef PYTHON3 | |
256 ifndef DYNAMIC_PYTHON3 | |
257 DYNAMIC_PYTHON3=yes | |
258 endif | |
259 | |
260 ifndef PYTHON3_VER | |
261 PYTHON3_VER=31 | |
262 endif | |
7695
a865f9773cb2
commit https://github.com/vim/vim/commit/a7c3795a2e65233ba2d187d680acc83bf6bf4ef5
Christian Brabandt <cb@256bit.org>
parents:
7609
diff
changeset
|
263 ifndef DYNAMIC_PYTHON3_DLL |
a865f9773cb2
commit https://github.com/vim/vim/commit/a7c3795a2e65233ba2d187d680acc83bf6bf4ef5
Christian Brabandt <cb@256bit.org>
parents:
7609
diff
changeset
|
264 DYNAMIC_PYTHON3_DLL=python$(PYTHON3_VER).dll |
a865f9773cb2
commit https://github.com/vim/vim/commit/a7c3795a2e65233ba2d187d680acc83bf6bf4ef5
Christian Brabandt <cb@256bit.org>
parents:
7609
diff
changeset
|
265 endif |
a865f9773cb2
commit https://github.com/vim/vim/commit/a7c3795a2e65233ba2d187d680acc83bf6bf4ef5
Christian Brabandt <cb@256bit.org>
parents:
7609
diff
changeset
|
266 ifdef PYTHON3_HOME |
8076
3b0127287851
commit https://github.com/vim/vim/commit/acd58ef676bb9559ac0f635f66b62f4602929c87
Christian Brabandt <cb@256bit.org>
parents:
8064
diff
changeset
|
267 PYTHON3_HOME_DEF=-DPYTHON3_HOME=L\"$(PYTHON3_HOME)\" |
7695
a865f9773cb2
commit https://github.com/vim/vim/commit/a7c3795a2e65233ba2d187d680acc83bf6bf4ef5
Christian Brabandt <cb@256bit.org>
parents:
7609
diff
changeset
|
268 endif |
6326 | 269 |
270 ifeq (no,$(DYNAMIC_PYTHON3)) | |
7695
a865f9773cb2
commit https://github.com/vim/vim/commit/a7c3795a2e65233ba2d187d680acc83bf6bf4ef5
Christian Brabandt <cb@256bit.org>
parents:
7609
diff
changeset
|
271 PYTHON3LIB=-L$(PYTHON3)/libs -lpython$(PYTHON3_VER) |
6326 | 272 endif |
273 | |
7695
a865f9773cb2
commit https://github.com/vim/vim/commit/a7c3795a2e65233ba2d187d680acc83bf6bf4ef5
Christian Brabandt <cb@256bit.org>
parents:
7609
diff
changeset
|
274 ifndef PYTHON3INC |
6326 | 275 ifeq ($(CROSS),no) |
276 PYTHON3INC=-I $(PYTHON3)/include | |
277 else | |
278 PYTHON3INC=-I $(PYTHON3)/win32inc | |
279 endif | |
280 endif | |
7695
a865f9773cb2
commit https://github.com/vim/vim/commit/a7c3795a2e65233ba2d187d680acc83bf6bf4ef5
Christian Brabandt <cb@256bit.org>
parents:
7609
diff
changeset
|
281 endif |
6326 | 282 |
283 # TCL interface: | |
284 # TCL=[Path to TCL directory] (Set inside Make_cyg.mak or Make_ming.mak) | |
285 # DYNAMIC_TCL=yes (to load the TCL DLL dynamically) | |
286 # TCL_VER=[TCL version, eg 83, 84] (default is 83) | |
7523
55cd9a99514d
commit https://github.com/vim/vim/commit/eca99bd45f094b1b12e22b9d6b206bd05dc9a38c
Christian Brabandt <cb@256bit.org>
parents:
7521
diff
changeset
|
287 # TCL_VER_LONG=[Tcl version, eg 8.3] (default is 8.3) |
55cd9a99514d
commit https://github.com/vim/vim/commit/eca99bd45f094b1b12e22b9d6b206bd05dc9a38c
Christian Brabandt <cb@256bit.org>
parents:
7521
diff
changeset
|
288 # You must set TCL_VER_LONG when you set TCL_VER. |
6326 | 289 ifdef TCL |
290 ifndef DYNAMIC_TCL | |
291 DYNAMIC_TCL=yes | |
292 endif | |
293 ifndef TCL_VER | |
294 TCL_VER = 83 | |
295 endif | |
7523
55cd9a99514d
commit https://github.com/vim/vim/commit/eca99bd45f094b1b12e22b9d6b206bd05dc9a38c
Christian Brabandt <cb@256bit.org>
parents:
7521
diff
changeset
|
296 ifndef TCL_VER_LONG |
55cd9a99514d
commit https://github.com/vim/vim/commit/eca99bd45f094b1b12e22b9d6b206bd05dc9a38c
Christian Brabandt <cb@256bit.org>
parents:
7521
diff
changeset
|
297 TCL_VER_LONG = 8.3 |
55cd9a99514d
commit https://github.com/vim/vim/commit/eca99bd45f094b1b12e22b9d6b206bd05dc9a38c
Christian Brabandt <cb@256bit.org>
parents:
7521
diff
changeset
|
298 endif |
6326 | 299 TCLINC += -I$(TCL)/include |
300 endif | |
301 | |
302 | |
303 # Ruby interface: | |
304 # RUBY=[Path to Ruby directory] (Set inside Make_cyg.mak or Make_ming.mak) | |
305 # DYNAMIC_RUBY=yes (to load the Ruby DLL dynamically) | |
306 # RUBY_VER=[Ruby version, eg 18, 19, 20] (default is 18) | |
307 # RUBY_VER_LONG=[Ruby version, eg 1.8, 1.9.1, 2.0.0] (default is 1.8) | |
308 # You must set RUBY_VER_LONG when changing RUBY_VER. | |
309 # RUBY_API_VER is derived from RUBY_VER_LONG. | |
310 # Note: If you use Ruby 1.9.3, set as follows: | |
311 # RUBY_VER=19 | |
312 # RUBY_VER_LONG=1.9.1 (not 1.9.3, because the API version is 1.9.1.) | |
313 ifdef RUBY | |
314 ifndef DYNAMIC_RUBY | |
315 DYNAMIC_RUBY=yes | |
316 endif | |
317 # Set default value | |
318 ifndef RUBY_VER | |
319 RUBY_VER = 18 | |
320 endif | |
321 ifndef RUBY_VER_LONG | |
322 RUBY_VER_LONG = 1.8 | |
323 endif | |
324 ifndef RUBY_API_VER | |
325 RUBY_API_VER = $(subst .,,$(RUBY_VER_LONG)) | |
326 endif | |
327 | |
328 ifndef RUBY_PLATFORM | |
329 ifeq ($(RUBY_VER), 16) | |
330 RUBY_PLATFORM = i586-mswin32 | |
331 else | |
332 ifneq ($(wildcard $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386-mingw32),) | |
333 RUBY_PLATFORM = i386-mingw32 | |
334 else | |
335 ifneq ($(wildcard $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/x64-mingw32),) | |
336 RUBY_PLATFORM = x64-mingw32 | |
337 else | |
338 RUBY_PLATFORM = i386-mswin32 | |
339 endif | |
340 endif | |
341 endif | |
342 endif | |
343 | |
344 ifndef RUBY_INSTALL_NAME | |
345 ifeq ($(RUBY_VER), 16) | |
346 RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_API_VER) | |
347 else | |
7521
665330ac1d78
commit https://github.com/vim/vim/commit/0bee2fe25aca7e8e5fefe55fe0f2c0e5e0878a98
Christian Brabandt <cb@256bit.org>
parents:
7456
diff
changeset
|
348 ifndef RUBY_MSVCRT_NAME |
665330ac1d78
commit https://github.com/vim/vim/commit/0bee2fe25aca7e8e5fefe55fe0f2c0e5e0878a98
Christian Brabandt <cb@256bit.org>
parents:
7456
diff
changeset
|
349 # Base name of msvcrXX.dll which is used by ruby's dll. |
665330ac1d78
commit https://github.com/vim/vim/commit/0bee2fe25aca7e8e5fefe55fe0f2c0e5e0878a98
Christian Brabandt <cb@256bit.org>
parents:
7456
diff
changeset
|
350 RUBY_MSVCRT_NAME = msvcrt |
665330ac1d78
commit https://github.com/vim/vim/commit/0bee2fe25aca7e8e5fefe55fe0f2c0e5e0878a98
Christian Brabandt <cb@256bit.org>
parents:
7456
diff
changeset
|
351 endif |
6326 | 352 ifeq ($(ARCH),x86-64) |
7521
665330ac1d78
commit https://github.com/vim/vim/commit/0bee2fe25aca7e8e5fefe55fe0f2c0e5e0878a98
Christian Brabandt <cb@256bit.org>
parents:
7456
diff
changeset
|
353 RUBY_INSTALL_NAME = x64-$(RUBY_MSVCRT_NAME)-ruby$(RUBY_API_VER) |
6326 | 354 else |
7521
665330ac1d78
commit https://github.com/vim/vim/commit/0bee2fe25aca7e8e5fefe55fe0f2c0e5e0878a98
Christian Brabandt <cb@256bit.org>
parents:
7456
diff
changeset
|
355 RUBY_INSTALL_NAME = $(RUBY_MSVCRT_NAME)-ruby$(RUBY_API_VER) |
6326 | 356 endif |
357 endif | |
358 endif | |
359 | |
360 ifeq (19, $(word 1,$(sort 19 $(RUBY_VER)))) | |
361 RUBY_19_OR_LATER = 1 | |
362 endif | |
363 | |
364 RUBYINC = -I $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/$(RUBY_PLATFORM) | |
365 ifdef RUBY_19_OR_LATER | |
366 RUBYINC += -I $(RUBY)/include/ruby-$(RUBY_VER_LONG) -I $(RUBY)/include/ruby-$(RUBY_VER_LONG)/$(RUBY_PLATFORM) | |
367 endif | |
368 ifeq (no, $(DYNAMIC_RUBY)) | |
369 RUBYLIB = -L$(RUBY)/lib -l$(RUBY_INSTALL_NAME) | |
370 endif | |
371 | |
372 endif # RUBY | |
373 | |
374 # See feature.h for a list of options. | |
375 # Any other defines can be included here. | |
376 DEF_GUI=-DFEAT_GUI_W32 -DFEAT_CLIPBOARD | |
377 DEFINES=-DWIN32 -DWINVER=$(WINVER) -D_WIN32_WINNT=$(WINVER) \ | |
378 -DHAVE_PATHDEF -DFEAT_$(FEATURES) | |
379 ifeq ($(ARCH),x86-64) | |
380 DEFINES+=-DMS_WIN64 | |
381 endif | |
382 ifeq ($(CROSS),yes) | |
383 # cross-compiler prefix: | |
384 ifndef CROSS_COMPILE | |
385 CROSS_COMPILE = i586-pc-mingw32msvc- | |
386 endif | |
387 DEL = rm | |
388 MKDIR = mkdir -p | |
389 DIRSLASH = / | |
390 else | |
391 # normal (Windows) compilation: | |
392 ifndef CROSS_COMPILE | |
393 CROSS_COMPILE = | |
394 endif | |
395 ifneq (sh.exe, $(SHELL)) | |
396 DEL = rm | |
397 MKDIR = mkdir -p | |
398 DIRSLASH = / | |
399 else | |
400 DEL = del | |
401 MKDIR = mkdir | |
402 DIRSLASH = \\ | |
403 endif | |
404 endif | |
405 CC := $(CROSS_COMPILE)gcc | |
406 CXX := $(CROSS_COMPILE)g++ | |
6436 | 407 ifeq ($(UNDER_CYGWIN),yes) |
6326 | 408 WINDRES := $(CROSS_COMPILE)windres |
6436 | 409 else |
410 WINDRES := windres | |
411 endif | |
6326 | 412 WINDRES_CC = $(CC) |
413 | |
414 #>>>>> end of choices | |
415 ########################################################################### | |
416 | |
8057
e407d5bce2f5
commit https://github.com/vim/vim/commit/a971df849f92e32e18ce475fdb47ad9ea2aa47f3
Christian Brabandt <cb@256bit.org>
parents:
8051
diff
changeset
|
417 CFLAGS = -Iproto $(DEFINES) -pipe -march=$(ARCH) -Wall |
8696
869727342e43
commit https://github.com/vim/vim/commit/6c0e984f263fc1eef42c9b34a80eff1bceb8d05b
Christian Brabandt <cb@256bit.org>
parents:
8641
diff
changeset
|
418 CXXFLAGS = -std=gnu++11 |
6326 | 419 WINDRES_FLAGS = --preprocessor="$(WINDRES_CC) -E -xc" -DRC_INVOKED |
420 EXTRA_LIBS = | |
421 | |
422 ifdef GETTEXT | |
423 DEFINES += -DHAVE_GETTEXT -DHAVE_LOCALE_H | |
424 GETTEXTINCLUDE = $(GETTEXT)/include | |
425 GETTEXTLIB = $(INTLPATH) | |
426 ifeq (yes, $(GETTEXT)) | |
427 DEFINES += -DDYNAMIC_GETTEXT | |
428 else | |
429 ifdef DYNAMIC_GETTEXT | |
430 DEFINES += -D$(DYNAMIC_GETTEXT) | |
431 ifdef GETTEXT_DYNAMIC | |
432 DEFINES += -DGETTEXT_DYNAMIC -DGETTEXT_DLL=\"$(GETTEXT_DYNAMIC)\" | |
433 endif | |
434 endif | |
435 endif | |
436 endif | |
437 | |
438 ifdef PERL | |
6872 | 439 CFLAGS += -I$(PERLLIBS) -DFEAT_PERL -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS |
6326 | 440 ifeq (yes, $(DYNAMIC_PERL)) |
441 CFLAGS += -DDYNAMIC_PERL -DDYNAMIC_PERL_DLL=\"perl$(PERL_VER).dll\" | |
442 EXTRA_LIBS += -L$(PERLLIBS) -lperl$(PERL_VER) | |
443 endif | |
444 endif | |
445 | |
446 ifdef LUA | |
447 CFLAGS += -I$(LUA)/include -I$(LUA) -DFEAT_LUA | |
448 ifeq (yes, $(DYNAMIC_LUA)) | |
449 CFLAGS += -DDYNAMIC_LUA -DDYNAMIC_LUA_DLL=\"lua$(LUA_VER).dll\" | |
450 endif | |
451 endif | |
452 | |
453 ifdef MZSCHEME | |
7609
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
454 ifndef MZSCHEME_COLLECTS |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
455 MZSCHEME_COLLECTS=$(MZSCHEME)/collects |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
456 ifeq (yes, $(UNDER_CYGWIN)) |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
457 MZSCHEME_COLLECTS:=$(shell cygpath -m $(MZSCHEME_COLLECTS) | sed -e 's/ /\\ /g') |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
458 endif |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
459 endif |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
460 CFLAGS += -I$(MZSCHEME)/include -DFEAT_MZSCHEME -DMZSCHEME_COLLECTS=\"$(MZSCHEME_COLLECTS)\" |
6326 | 461 ifeq (yes, $(DYNAMIC_MZSCHEME)) |
7609
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
462 ifeq (yes, $(MZSCHEME_PRECISE_GC)) |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
463 # Precise GC does not use separate dll |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
464 CFLAGS += -DDYNAMIC_MZSCHEME -DDYNAMIC_MZSCH_DLL=\"lib$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER).dll\" -DDYNAMIC_MZGC_DLL=\"lib$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER).dll\" |
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
465 else |
6326 | 466 CFLAGS += -DDYNAMIC_MZSCHEME -DDYNAMIC_MZSCH_DLL=\"lib$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER).dll\" -DDYNAMIC_MZGC_DLL=\"libmzgc$(MZSCHEME_VER).dll\" |
467 endif | |
7609
77a14f3bc18b
commit https://github.com/vim/vim/commit/4e640bd930d133889dbc9f9a77e29bab902e3b7d
Christian Brabandt <cb@256bit.org>
parents:
7532
diff
changeset
|
468 endif |
6326 | 469 ifeq (yes, "$(MZSCHEME_DEBUG)") |
470 CFLAGS += -DMZSCHEME_FORCE_GC | |
471 endif | |
472 endif | |
473 | |
474 ifdef RUBY | |
475 CFLAGS += -DFEAT_RUBY $(RUBYINC) | |
476 ifeq (yes, $(DYNAMIC_RUBY)) | |
477 CFLAGS += -DDYNAMIC_RUBY -DDYNAMIC_RUBY_DLL=\"$(RUBY_INSTALL_NAME).dll\" | |
478 CFLAGS += -DDYNAMIC_RUBY_VER=$(RUBY_VER) | |
479 endif | |
480 ifneq ($(findstring w64-mingw32,$(CC)),) | |
481 # A workaround for MinGW-w64 | |
482 CFLAGS += -DHAVE_STRUCT_TIMESPEC -DHAVE_STRUCT_TIMEZONE | |
483 endif | |
484 endif | |
485 | |
486 ifdef PYTHON | |
8120
350f8040bd37
commit https://github.com/vim/vim/commit/223b723be0703137cf6373e23f8ae5c02e92ef82
Christian Brabandt <cb@256bit.org>
parents:
8076
diff
changeset
|
487 CFLAGS += -DFEAT_PYTHON |
6326 | 488 ifeq (yes, $(DYNAMIC_PYTHON)) |
7532
0acbe61244ac
commit https://github.com/vim/vim/commit/449538c3d2f7089dcaa1a888f09f41714faec9a6
Christian Brabandt <cb@256bit.org>
parents:
7523
diff
changeset
|
489 CFLAGS += -DDYNAMIC_PYTHON -DDYNAMIC_PYTHON_DLL=\"$(DYNAMIC_PYTHON_DLL)\" |
6326 | 490 endif |
491 endif | |
492 | |
8120
350f8040bd37
commit https://github.com/vim/vim/commit/223b723be0703137cf6373e23f8ae5c02e92ef82
Christian Brabandt <cb@256bit.org>
parents:
8076
diff
changeset
|
493 ifdef PYTHON3 |
350f8040bd37
commit https://github.com/vim/vim/commit/223b723be0703137cf6373e23f8ae5c02e92ef82
Christian Brabandt <cb@256bit.org>
parents:
8076
diff
changeset
|
494 CFLAGS += -DFEAT_PYTHON3 |
6326 | 495 ifeq (yes, $(DYNAMIC_PYTHON3)) |
7695
a865f9773cb2
commit https://github.com/vim/vim/commit/a7c3795a2e65233ba2d187d680acc83bf6bf4ef5
Christian Brabandt <cb@256bit.org>
parents:
7609
diff
changeset
|
496 CFLAGS += -DDYNAMIC_PYTHON3 -DDYNAMIC_PYTHON3_DLL=\"$(DYNAMIC_PYTHON3_DLL)\" |
6326 | 497 endif |
498 endif | |
499 | |
500 ifdef TCL | |
501 CFLAGS += -DFEAT_TCL $(TCLINC) | |
502 ifeq (yes, $(DYNAMIC_TCL)) | |
7523
55cd9a99514d
commit https://github.com/vim/vim/commit/eca99bd45f094b1b12e22b9d6b206bd05dc9a38c
Christian Brabandt <cb@256bit.org>
parents:
7521
diff
changeset
|
503 CFLAGS += -DDYNAMIC_TCL -DDYNAMIC_TCL_DLL=\"tcl$(TCL_VER).dll\" -DDYNAMIC_TCL_VER=\"$(TCL_VER_LONG)\" |
6326 | 504 endif |
505 endif | |
506 | |
507 ifeq ($(POSTSCRIPT),yes) | |
508 DEFINES += -DMSWINPS | |
509 endif | |
510 | |
511 ifeq (yes, $(OLE)) | |
512 DEFINES += -DFEAT_OLE | |
513 endif | |
514 | |
515 ifeq ($(CSCOPE),yes) | |
516 DEFINES += -DFEAT_CSCOPE | |
517 endif | |
518 | |
519 ifeq ($(NETBEANS),yes) | |
520 # Only allow NETBEANS for a GUI build. | |
521 ifeq (yes, $(GUI)) | |
522 DEFINES += -DFEAT_NETBEANS_INTG | |
523 | |
524 ifeq ($(NBDEBUG), yes) | |
525 DEFINES += -DNBDEBUG | |
526 NBDEBUG_INCL = nbdebug.h | |
527 NBDEBUG_SRC = nbdebug.c | |
528 endif | |
529 endif | |
530 endif | |
531 | |
7743
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
532 ifeq ($(CHANNEL),yes) |
8493
caed4b2d305f
commit https://github.com/vim/vim/commit/509ce2a558e7e0c03242e32e844255af52f1c821
Christian Brabandt <cb@256bit.org>
parents:
8140
diff
changeset
|
533 DEFINES += -DFEAT_JOB_CHANNEL |
7743
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
534 endif |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
535 |
6326 | 536 # DirectWrite (DirectX) |
537 ifeq ($(DIRECTX),yes) | |
538 # Only allow DirectWrite for a GUI build. | |
539 ifeq (yes, $(GUI)) | |
540 DEFINES += -DFEAT_DIRECTX -DDYNAMIC_DIRECTX | |
541 endif | |
542 endif | |
543 | |
544 # Only allow XPM for a GUI build. | |
545 ifeq (yes, $(GUI)) | |
546 | |
547 ifndef XPM | |
548 ifeq ($(ARCH),i386) | |
549 XPM = xpm/x86 | |
550 endif | |
551 ifeq ($(ARCH),i486) | |
552 XPM = xpm/x86 | |
553 endif | |
554 ifeq ($(ARCH),i586) | |
555 XPM = xpm/x86 | |
556 endif | |
557 ifeq ($(ARCH),i686) | |
558 XPM = xpm/x86 | |
559 endif | |
560 ifeq ($(ARCH),x86-64) | |
561 XPM = xpm/x64 | |
562 endif | |
563 endif | |
564 ifdef XPM | |
565 ifneq ($(XPM),no) | |
566 CFLAGS += -DFEAT_XPM_W32 -I $(XPM)/include -I $(XPM)/../include | |
567 endif | |
568 endif | |
569 | |
570 endif | |
571 | |
572 ifeq ($(DEBUG),yes) | |
573 CFLAGS += -g -fstack-check | |
574 DEBUG_SUFFIX=d | |
575 else | |
576 ifeq ($(OPTIMIZE), SIZE) | |
577 CFLAGS += -Os | |
578 else | |
579 ifeq ($(OPTIMIZE), MAXSPEED) | |
580 CFLAGS += -O3 | |
581 CFLAGS += -fomit-frame-pointer -freg-struct-return | |
582 else # SPEED | |
583 CFLAGS += -O2 | |
584 endif | |
585 endif | |
586 CFLAGS += -s | |
587 endif | |
588 | |
589 LIB = -lkernel32 -luser32 -lgdi32 -ladvapi32 -lcomdlg32 -lcomctl32 -lversion | |
590 GUIOBJ = $(OUTDIR)/gui.o $(OUTDIR)/gui_w32.o $(OUTDIR)/gui_beval.o $(OUTDIR)/os_w32exe.o | |
591 OBJ = \ | |
592 $(OUTDIR)/blowfish.o \ | |
593 $(OUTDIR)/buffer.o \ | |
594 $(OUTDIR)/charset.o \ | |
595 $(OUTDIR)/crypt.o \ | |
596 $(OUTDIR)/crypt_zip.o \ | |
597 $(OUTDIR)/diff.o \ | |
598 $(OUTDIR)/digraph.o \ | |
599 $(OUTDIR)/edit.o \ | |
600 $(OUTDIR)/eval.o \ | |
601 $(OUTDIR)/ex_cmds.o \ | |
602 $(OUTDIR)/ex_cmds2.o \ | |
603 $(OUTDIR)/ex_docmd.o \ | |
604 $(OUTDIR)/ex_eval.o \ | |
605 $(OUTDIR)/ex_getln.o \ | |
606 $(OUTDIR)/fileio.o \ | |
607 $(OUTDIR)/fold.o \ | |
608 $(OUTDIR)/getchar.o \ | |
609 $(OUTDIR)/hardcopy.o \ | |
610 $(OUTDIR)/hashtab.o \ | |
7712
bce3b5ddb393
commit https://github.com/vim/vim/commit/520e1e41f35b063ede63b41738c82d6636e78c34
Christian Brabandt <cb@256bit.org>
parents:
7699
diff
changeset
|
611 $(OUTDIR)/json.o \ |
6326 | 612 $(OUTDIR)/main.o \ |
613 $(OUTDIR)/mark.o \ | |
614 $(OUTDIR)/memfile.o \ | |
615 $(OUTDIR)/memline.o \ | |
616 $(OUTDIR)/menu.o \ | |
617 $(OUTDIR)/message.o \ | |
618 $(OUTDIR)/misc1.o \ | |
619 $(OUTDIR)/misc2.o \ | |
620 $(OUTDIR)/move.o \ | |
621 $(OUTDIR)/mbyte.o \ | |
622 $(OUTDIR)/normal.o \ | |
623 $(OUTDIR)/ops.o \ | |
624 $(OUTDIR)/option.o \ | |
625 $(OUTDIR)/os_win32.o \ | |
626 $(OUTDIR)/os_mswin.o \ | |
627 $(OUTDIR)/winclip.o \ | |
628 $(OUTDIR)/pathdef.o \ | |
629 $(OUTDIR)/popupmnu.o \ | |
630 $(OUTDIR)/quickfix.o \ | |
631 $(OUTDIR)/regexp.o \ | |
632 $(OUTDIR)/screen.o \ | |
633 $(OUTDIR)/search.o \ | |
634 $(OUTDIR)/sha256.o \ | |
635 $(OUTDIR)/spell.o \ | |
636 $(OUTDIR)/syntax.o \ | |
637 $(OUTDIR)/tag.o \ | |
638 $(OUTDIR)/term.o \ | |
639 $(OUTDIR)/ui.o \ | |
640 $(OUTDIR)/undo.o \ | |
641 $(OUTDIR)/version.o \ | |
642 $(OUTDIR)/vimrc.o \ | |
643 $(OUTDIR)/window.o | |
644 | |
645 ifdef PERL | |
646 OBJ += $(OUTDIR)/if_perl.o | |
647 endif | |
648 ifdef LUA | |
649 OBJ += $(OUTDIR)/if_lua.o | |
650 endif | |
651 ifdef MZSCHEME | |
652 OBJ += $(OUTDIR)/if_mzsch.o | |
653 MZSCHEME_INCL = if_mzsch.h | |
654 ifeq (yes,$(MZSCHEME_GENERATE_BASE)) | |
655 CFLAGS += -DINCLUDE_MZSCHEME_BASE | |
656 MZ_EXTRA_DEP += mzscheme_base.c | |
657 endif | |
658 ifeq (yes,$(MZSCHEME_PRECISE_GC)) | |
659 CFLAGS += -DMZ_PRECISE_GC | |
660 endif | |
661 endif | |
662 ifdef PYTHON | |
663 OBJ += $(OUTDIR)/if_python.o | |
664 endif | |
665 ifdef PYTHON3 | |
666 OBJ += $(OUTDIR)/if_python3.o | |
667 endif | |
668 ifdef RUBY | |
669 OBJ += $(OUTDIR)/if_ruby.o | |
670 endif | |
671 ifdef TCL | |
672 OBJ += $(OUTDIR)/if_tcl.o | |
673 endif | |
674 ifeq ($(CSCOPE),yes) | |
675 OBJ += $(OUTDIR)/if_cscope.o | |
676 endif | |
7743
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
677 |
6326 | 678 ifeq ($(NETBEANS),yes) |
7743
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
679 ifneq ($(CHANNEL),yes) |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
680 # Cannot use Netbeans without CHANNEL |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
681 NETBEANS=no |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
682 else |
8051
7e298e8c5741
commit https://github.com/vim/vim/commit/44d571868f4fcf000e8b03ee0a350f1f8131c9ca
Christian Brabandt <cb@256bit.org>
parents:
7755
diff
changeset
|
683 ifneq (yes, $(GUI)) |
7e298e8c5741
commit https://github.com/vim/vim/commit/44d571868f4fcf000e8b03ee0a350f1f8131c9ca
Christian Brabandt <cb@256bit.org>
parents:
7755
diff
changeset
|
684 # Cannot use Netbeans without GUI. |
7e298e8c5741
commit https://github.com/vim/vim/commit/44d571868f4fcf000e8b03ee0a350f1f8131c9ca
Christian Brabandt <cb@256bit.org>
parents:
7755
diff
changeset
|
685 NETBEANS=no |
7e298e8c5741
commit https://github.com/vim/vim/commit/44d571868f4fcf000e8b03ee0a350f1f8131c9ca
Christian Brabandt <cb@256bit.org>
parents:
7755
diff
changeset
|
686 else |
6326 | 687 OBJ += $(OUTDIR)/netbeans.o |
688 endif | |
689 endif | |
7743
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
690 endif |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
691 |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
692 ifeq ($(CHANNEL),yes) |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
693 OBJ += $(OUTDIR)/channel.o |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
694 LIB += -lwsock32 |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
695 endif |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
696 |
6326 | 697 ifeq ($(DIRECTX),yes) |
698 # Only allow DIRECTX for a GUI build. | |
699 ifeq (yes, $(GUI)) | |
700 OBJ += $(OUTDIR)/gui_dwrite.o | |
701 LIB += -ld2d1 -ldwrite | |
702 USE_STDCPLUS = yes | |
703 endif | |
704 endif | |
705 ifneq ($(XPM),no) | |
706 # Only allow XPM for a GUI build. | |
707 ifeq (yes, $(GUI)) | |
708 OBJ += $(OUTDIR)/xpm_w32.o | |
709 # You'll need libXpm.a from http://gnuwin32.sf.net | |
710 LIB += -L$(XPM)/lib -lXpm | |
711 endif | |
712 endif | |
713 | |
714 | |
715 ifdef MZSCHEME | |
716 MZSCHEME_SUFFIX = Z | |
717 endif | |
718 | |
719 ifeq ($(GUI),yes) | |
720 TARGET := gvim$(DEBUG_SUFFIX).exe | |
721 DEFINES += $(DEF_GUI) | |
722 OBJ += $(GUIOBJ) | |
723 LFLAGS += -mwindows | |
724 OUTDIR = gobj$(DEBUG_SUFFIX)$(MZSCHEME_SUFFIX)$(ARCH) | |
725 else | |
726 TARGET := vim$(DEBUG_SUFFIX).exe | |
727 OUTDIR = obj$(DEBUG_SUFFIX)$(MZSCHEME_SUFFIX)$(ARCH) | |
728 endif | |
729 | |
730 ifdef GETTEXT | |
731 ifneq (yes, $(GETTEXT)) | |
732 CFLAGS += -I$(GETTEXTINCLUDE) | |
733 ifndef STATIC_GETTEXT | |
734 LIB += -L$(GETTEXTLIB) -l$(INTLLIB) | |
735 ifeq (USE_SAFE_GETTEXT_DLL, $(DYNAMIC_GETTEXT)) | |
736 OBJ+=$(SAFE_GETTEXT_DLL_OBJ) | |
737 endif | |
738 else | |
739 LIB += -L$(GETTEXTLIB) -lintl | |
740 endif | |
741 endif | |
742 endif | |
743 | |
744 ifdef PERL | |
745 ifeq (no, $(DYNAMIC_PERL)) | |
746 LIB += -L$(PERLLIBS) -lperl$(PERL_VER) | |
747 endif | |
748 endif | |
749 | |
750 ifdef TCL | |
751 LIB += -L$(TCL)/lib | |
752 ifeq (yes, $(DYNAMIC_TCL)) | |
753 LIB += -ltclstub$(TCL_VER) | |
754 else | |
755 LIB += -ltcl$(TCL_VER) | |
756 endif | |
757 endif | |
758 | |
759 ifeq (yes, $(OLE)) | |
760 LIB += -loleaut32 | |
761 OBJ += $(OUTDIR)/if_ole.o | |
762 USE_STDCPLUS = yes | |
763 endif | |
764 | |
765 ifeq (yes, $(MBYTE)) | |
766 DEFINES += -DFEAT_MBYTE | |
767 endif | |
768 | |
769 ifeq (yes, $(IME)) | |
770 DEFINES += -DFEAT_MBYTE_IME | |
771 ifeq (yes, $(DYNAMIC_IME)) | |
772 DEFINES += -DDYNAMIC_IME | |
773 else | |
774 LIB += -limm32 | |
775 endif | |
776 endif | |
777 | |
778 ifdef ICONV | |
779 ifneq (yes, $(ICONV)) | |
780 LIB += -L$(ICONV) | |
781 CFLAGS += -I$(ICONV) | |
782 endif | |
783 DEFINES+=-DDYNAMIC_ICONV | |
784 endif | |
785 | |
786 ifeq (yes, $(USE_STDCPLUS)) | |
787 ifeq (yes, $(STATIC_STDCPLUS)) | |
788 LIB += -Wl,-Bstatic -lstdc++ -Wl,-Bdynamic | |
789 else | |
790 LIB += -lstdc++ | |
791 endif | |
792 endif | |
793 | |
794 all: $(TARGET) vimrun.exe xxd/xxd.exe install.exe uninstal.exe GvimExt/gvimext.dll | |
795 | |
796 vimrun.exe: vimrun.c | |
797 $(CC) $(CFLAGS) -o vimrun.exe vimrun.c $(LIB) | |
798 | |
799 install.exe: dosinst.c | |
800 $(CC) $(CFLAGS) -o install.exe dosinst.c $(LIB) -lole32 -luuid | |
801 | |
802 uninstal.exe: uninstal.c | |
803 $(CC) $(CFLAGS) -o uninstal.exe uninstal.c $(LIB) | |
804 | |
805 $(TARGET): $(OUTDIR) $(OBJ) | |
806 $(CC) $(CFLAGS) $(LFLAGS) -o $@ $(OBJ) $(LIB) -lole32 -luuid $(LUA_LIB) $(MZSCHEME_LIBDIR) $(MZSCHEME_LIB) $(PYTHONLIB) $(PYTHON3LIB) $(RUBYLIB) | |
807 | |
808 upx: exes | |
809 upx gvim.exe | |
810 upx vim.exe | |
811 | |
812 mpress: exes | |
813 mpress gvim.exe | |
814 mpress vim.exe | |
815 | |
816 xxd/xxd.exe: xxd/xxd.c | |
817 $(MAKE) -C xxd -f Make_ming.mak CC='$(CC)' | |
818 | |
819 GvimExt/gvimext.dll: GvimExt/gvimext.cpp GvimExt/gvimext.rc GvimExt/gvimext.h | |
820 $(MAKE) -C GvimExt -f Make_ming.mak CROSS=$(CROSS) CROSS_COMPILE=$(CROSS_COMPILE) CXX='$(CXX)' STATIC_STDCPLUS=$(STATIC_STDCPLUS) | |
821 | |
822 clean: | |
823 -$(DEL) $(OUTDIR)$(DIRSLASH)*.o | |
824 -$(DEL) $(OUTDIR)$(DIRSLASH)*.res | |
825 -rmdir $(OUTDIR) | |
826 -$(DEL) *.exe | |
827 -$(DEL) pathdef.c | |
828 ifdef PERL | |
829 -$(DEL) if_perl.c | |
830 endif | |
831 ifdef MZSCHEME | |
832 -$(DEL) mzscheme_base.c | |
833 endif | |
834 $(MAKE) -C GvimExt -f Make_ming.mak clean | |
835 $(MAKE) -C xxd -f Make_ming.mak clean | |
836 | |
837 ########################################################################### | |
838 INCL = vim.h feature.h os_win32.h os_dos.h ascii.h keymap.h term.h macros.h \ | |
839 structs.h regexp.h option.h ex_cmds.h proto.h globals.h farsi.h \ | |
840 gui.h | |
841 | |
842 $(OUTDIR)/if_python.o : if_python.c if_py_both.h $(INCL) | |
7532
0acbe61244ac
commit https://github.com/vim/vim/commit/449538c3d2f7089dcaa1a888f09f41714faec9a6
Christian Brabandt <cb@256bit.org>
parents:
7523
diff
changeset
|
843 $(CC) -c $(CFLAGS) $(PYTHONINC) $(PYTHON_HOME_DEF) $< -o $@ |
6326 | 844 |
845 $(OUTDIR)/if_python3.o : if_python3.c if_py_both.h $(INCL) | |
7695
a865f9773cb2
commit https://github.com/vim/vim/commit/a7c3795a2e65233ba2d187d680acc83bf6bf4ef5
Christian Brabandt <cb@256bit.org>
parents:
7609
diff
changeset
|
846 $(CC) -c $(CFLAGS) $(PYTHON3INC) $(PYTHON3_HOME_DEF) $< -o $@ |
6326 | 847 |
848 $(OUTDIR)/%.o : %.c $(INCL) | |
849 $(CC) -c $(CFLAGS) $< -o $@ | |
850 | |
851 $(OUTDIR)/vimrc.o: vim.rc version.h gui_w32_rc.h | |
852 $(WINDRES) $(WINDRES_FLAGS) $(DEFINES) \ | |
853 --input-format=rc --output-format=coff -i vim.rc -o $@ | |
854 | |
855 $(OUTDIR): | |
856 $(MKDIR) $(OUTDIR) | |
857 | |
858 $(OUTDIR)/ex_docmd.o: ex_docmd.c $(INCL) ex_cmds.h | |
859 $(CC) -c $(CFLAGS) ex_docmd.c -o $(OUTDIR)/ex_docmd.o | |
860 | |
861 $(OUTDIR)/ex_eval.o: ex_eval.c $(INCL) ex_cmds.h | |
862 $(CC) -c $(CFLAGS) ex_eval.c -o $(OUTDIR)/ex_eval.o | |
863 | |
8140
563c923b1584
commit https://github.com/vim/vim/commit/cf7164a088664961e7d70dd100c5874dc5ceb293
Christian Brabandt <cb@256bit.org>
parents:
8120
diff
changeset
|
864 $(OUTDIR)/gui_w32.o: gui_w32.c $(INCL) |
6326 | 865 $(CC) -c $(CFLAGS) gui_w32.c -o $(OUTDIR)/gui_w32.o |
866 | |
867 $(OUTDIR)/gui_dwrite.o: gui_dwrite.cpp $(INCL) gui_dwrite.h | |
8641
0af716a4f5d2
commit https://github.com/vim/vim/commit/cc6cf9b9f9045a7d8b5923ea0c556e9a4c2567d3
Christian Brabandt <cb@256bit.org>
parents:
8493
diff
changeset
|
868 $(CC) -c $(CFLAGS) $(CXXFLAGS) gui_dwrite.cpp -o $(OUTDIR)/gui_dwrite.o |
6326 | 869 |
870 $(OUTDIR)/if_cscope.o: if_cscope.c $(INCL) if_cscope.h | |
871 $(CC) -c $(CFLAGS) if_cscope.c -o $(OUTDIR)/if_cscope.o | |
872 | |
873 # Remove -D__IID_DEFINED__ for newer versions of the w32api | |
874 $(OUTDIR)/if_ole.o: if_ole.cpp $(INCL) | |
8641
0af716a4f5d2
commit https://github.com/vim/vim/commit/cc6cf9b9f9045a7d8b5923ea0c556e9a4c2567d3
Christian Brabandt <cb@256bit.org>
parents:
8493
diff
changeset
|
875 $(CC) $(CFLAGS) $(CXXFLAGS) -c -o $(OUTDIR)/if_ole.o if_ole.cpp |
6326 | 876 |
877 $(OUTDIR)/if_ruby.o: if_ruby.c $(INCL) | |
878 ifeq (16, $(RUBY)) | |
879 $(CC) $(CFLAGS) -U_WIN32 -c -o $(OUTDIR)/if_ruby.o if_ruby.c | |
880 endif | |
881 | |
882 if_perl.c: if_perl.xs typemap | |
883 $(XSUBPP) -prototypes -typemap \ | |
6349 | 884 $(PERLTYPEMAP) if_perl.xs > $@ |
6326 | 885 |
886 $(OUTDIR)/netbeans.o: netbeans.c $(INCL) $(NBDEBUG_INCL) $(NBDEBUG_SRC) | |
887 $(CC) -c $(CFLAGS) netbeans.c -o $(OUTDIR)/netbeans.o | |
888 | |
7743
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
889 $(OUTDIR)/channel.o: channel.c $(INCL) |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
890 $(CC) -c $(CFLAGS) channel.c -o $(OUTDIR)/channel.o |
6069f43cea4e
commit https://github.com/vim/vim/commit/e0874f8cbcddfcf9965a85ba35199964efb1d01a
Christian Brabandt <cb@256bit.org>
parents:
7712
diff
changeset
|
891 |
6326 | 892 $(OUTDIR)/regexp.o: regexp.c regexp_nfa.c $(INCL) |
893 $(CC) -c $(CFLAGS) regexp.c -o $(OUTDIR)/regexp.o | |
894 | |
895 $(OUTDIR)/if_mzsch.o: if_mzsch.c $(INCL) if_mzsch.h $(MZ_EXTRA_DEP) | |
896 $(CC) -c $(CFLAGS) if_mzsch.c -o $(OUTDIR)/if_mzsch.o | |
897 | |
898 mzscheme_base.c: | |
899 $(MZSCHEME)/mzc --c-mods mzscheme_base.c ++lib scheme/base | |
900 | |
901 pathdef.c: $(INCL) | |
902 ifneq (sh.exe, $(SHELL)) | |
903 @echo creating pathdef.c | |
904 @echo '/* pathdef.c */' > pathdef.c | |
905 @echo '#include "vim.h"' >> pathdef.c | |
906 @echo 'char_u *default_vim_dir = (char_u *)"$(VIMRCLOC)";' >> pathdef.c | |
907 @echo 'char_u *default_vimruntime_dir = (char_u *)"$(VIMRUNTIMEDIR)";' >> pathdef.c | |
908 @echo 'char_u *all_cflags = (char_u *)"$(CC) $(CFLAGS)";' >> pathdef.c | |
909 @echo 'char_u *all_lflags = (char_u *)"$(CC) $(CFLAGS) $(LFLAGS) -o $(TARGET) $(LIB) -lole32 -luuid $(LUA_LIB) $(MZSCHEME_LIBDIR) $(MZSCHEME_LIB) $(PYTHONLIB) $(PYTHON3LIB) $(RUBYLIB)";' >> pathdef.c | |
910 @echo 'char_u *compiled_user = (char_u *)"$(USERNAME)";' >> pathdef.c | |
911 @echo 'char_u *compiled_sys = (char_u *)"$(USERDOMAIN)";' >> pathdef.c | |
912 else | |
913 @echo creating pathdef.c | |
914 @echo /* pathdef.c */ > pathdef.c | |
915 @echo #include "vim.h" >> pathdef.c | |
916 @echo char_u *default_vim_dir = (char_u *)"$(VIMRCLOC)"; >> pathdef.c | |
917 @echo char_u *default_vimruntime_dir = (char_u *)"$(VIMRUNTIMEDIR)"; >> pathdef.c | |
918 @echo char_u *all_cflags = (char_u *)"$(CC) $(CFLAGS)"; >> pathdef.c | |
919 @echo char_u *all_lflags = (char_u *)"$(CC) $(CFLAGS) $(LFLAGS) -o $(TARGET) $(LIB) -lole32 -luuid $(LUA_LIB) $(MZSCHEME_LIBDIR) $(MZSCHEME_LIB) $(PYTHONLIB) $(PYTHON3LIB) $(RUBYLIB)"; >> pathdef.c | |
920 @echo char_u *compiled_user = (char_u *)"$(USERNAME)"; >> pathdef.c | |
921 @echo char_u *compiled_sys = (char_u *)"$(USERDOMAIN)"; >> pathdef.c | |
922 endif |