blob: d0769c39ee97cf02e4f10a60426d930c0698cd31 [file] [log] [blame]
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001# 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:
Bram Moolenaar43cb6262018-03-14 21:39:02 +010023# https://upx.github.io/
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010024# "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:
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010031# FEATURES=[TINY | SMALL | NORMAL | BIG | HUGE]
32# Set to TINY to make minimal version (few features).
Bram Moolenaare5f2be62016-01-21 20:24:34 +010033FEATURES=HUGE
Bram Moolenaarcccd62d2018-04-12 20:23:48 +020034
35# set to yes for a debug build
36DEBUG=no
37
Bram Moolenaar4ff42902018-09-21 14:43:10 +020038# set to yes to create a mapfile
Bram Moolenaarafde13b2019-04-28 19:46:49 +020039#MAP=yes
Bram Moolenaar4ff42902018-09-21 14:43:10 +020040
Bram Moolenaarcccd62d2018-04-12 20:23:48 +020041# set to SIZE for size, SPEED for speed, MAXSPEED for maximum optimization
42OPTIMIZE=MAXSPEED
43
44# set to yes to make gvim, no for vim
45GUI=yes
46
Bram Moolenaarafde13b2019-04-28 19:46:49 +020047# set to yes to enable the DLL support (EXPERIMENTAL).
48# Creates vim{32,64}.dll, and stub gvim.exe and vim.exe.
49# "GUI" should be also set to "yes".
50#VIMDLL=yes
51
Bram Moolenaarcccd62d2018-04-12 20:23:48 +020052# set to no if you do not want to use DirectWrite (DirectX)
53# MinGW-w64 is needed, and ARCH should be set to i686 or x86-64.
54DIRECTX=yes
55
56# Disable Color emoji support
57# (default is yes if DIRECTX=yes, requires WinSDK 8.1 or later.)
58#COLOR_EMOJI=no
59
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010060# Set to one of i386, i486, i586, i686 as the minimum target processor.
61# For amd64/x64 architecture set ARCH=x86-64 .
Bram Moolenaare0485392016-07-12 21:17:03 +020062# If not set, it will be automatically detected. (Normally i686 or x86-64.)
63#ARCH=i686
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010064# Set to yes to cross-compile from unix; no=native Windows (and Cygwin).
65CROSS=no
Bram Moolenaarcccd62d2018-04-12 20:23:48 +020066
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010067# Set to path to iconv.h and libiconv.a to enable using 'iconv.dll'.
Bram Moolenaarac8069b2017-10-14 20:24:19 +020068# Use "yes" when the path does not need to be define.
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010069#ICONV="."
70ICONV=yes
71GETTEXT=yes
Bram Moolenaarcccd62d2018-04-12 20:23:48 +020072
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010073# Set to yes to include IME support.
74IME=yes
75DYNAMIC_IME=yes
Bram Moolenaarcccd62d2018-04-12 20:23:48 +020076
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010077# Set to yes to enable writing a postscript file with :hardcopy.
78POSTSCRIPT=no
Bram Moolenaarcccd62d2018-04-12 20:23:48 +020079
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010080# Set to yes to enable OLE support.
81OLE=no
Bram Moolenaarcccd62d2018-04-12 20:23:48 +020082
Bram Moolenaar304925e2018-06-30 16:27:02 +020083# Set the default $(WINVER). Use 0x0501 to make it work with WinXP.
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010084ifndef WINVER
Bram Moolenaar304925e2018-06-30 16:27:02 +020085# WINVER = 0x0501
86WINVER = 0x0600
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010087endif
Bram Moolenaarcccd62d2018-04-12 20:23:48 +020088
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010089# Set to yes to enable Cscope support.
90CSCOPE=yes
Bram Moolenaarcccd62d2018-04-12 20:23:48 +020091
Bram Moolenaare0874f82016-01-24 20:36:41 +010092# Set to yes to enable Netbeans support (requires CHANNEL).
Bram Moolenaar4f7e8212014-11-05 13:53:32 +010093NETBEANS=$(GUI)
Bram Moolenaarcccd62d2018-04-12 20:23:48 +020094
Bram Moolenaare0874f82016-01-24 20:36:41 +010095# Set to yes to enable inter process communication.
Bram Moolenaar1aa07bd2016-06-03 19:43:16 +020096ifeq (HUGE, $(FEATURES))
97CHANNEL=yes
98else
Bram Moolenaare0874f82016-01-24 20:36:41 +010099CHANNEL=$(GUI)
Bram Moolenaar1aa07bd2016-06-03 19:43:16 +0200100endif
Bram Moolenaarcccd62d2018-04-12 20:23:48 +0200101
Bram Moolenaar8a773062017-07-24 22:29:21 +0200102# Set to yes to enable terminal support.
Bram Moolenaarac8069b2017-10-14 20:24:19 +0200103ifeq (HUGE, $(FEATURES))
104TERMINAL=yes
105else
Bram Moolenaar4fc63502017-07-19 11:28:17 +0200106TERMINAL=no
Bram Moolenaarac8069b2017-10-14 20:24:19 +0200107endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100108
Bram Moolenaar9b283522019-06-17 22:19:33 +0200109# Set to yes to enable sound support.
110ifneq ($(findstring $(FEATURES),BIG HUGE),)
111SOUND=yes
112else
113SOUND=no
114endif
115
Bram Moolenaar9ac9dfa2017-09-01 18:41:26 +0200116ifndef CTAGS
117# this assumes ctags is Exuberant ctags
118CTAGS = ctags -I INIT+ --fields=+S
119endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100120
121# Link against the shared version of libstdc++ by default. Set
122# STATIC_STDCPLUS to "yes" to link against static version instead.
123ifndef STATIC_STDCPLUS
124STATIC_STDCPLUS=no
125endif
126
Bram Moolenaare3af7632016-12-01 20:37:47 +0100127
128# Link against the shared version of libwinpthread by default. Set
129# STATIC_WINPTHREAD to "yes" to link against static version instead.
130ifndef STATIC_WINPTHREAD
131STATIC_WINPTHREAD=$(STATIC_STDCPLUS)
132endif
Bram Moolenaareda9e9c2018-10-21 22:45:43 +0200133# If you use TDM-GCC(-64), change HAS_GCC_EH to "no".
134# This is used when STATIC_STDCPLUS=yes.
135HAS_GCC_EH=yes
Bram Moolenaare3af7632016-12-01 20:37:47 +0100136
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100137# If the user doesn't want gettext, undefine it.
138ifeq (no, $(GETTEXT))
139GETTEXT=
140endif
141# Added by E.F. Amatria <eferna1@platea.ptic.mec.es> 2001 Feb 23
142# Uncomment the first line and one of the following three if you want Native Language
143# Support. You'll need gnu_gettext.win32, a MINGW32 Windows PORT of gettext by
144# Franco Bez <franco.bez@gmx.de>. It may be found at
145# http://home.a-city.de/franco.bez/gettext/gettext_win32_en.html
146# Tested with mingw32 with GCC-2.95.2 on Win98
147# Updated 2001 Jun 9
148#GETTEXT=c:/gettext.win32.msvcrt
149#STATIC_GETTEXT=USE_STATIC_GETTEXT
150#DYNAMIC_GETTEXT=USE_GETTEXT_DLL
151#DYNAMIC_GETTEXT=USE_SAFE_GETTEXT_DLL
152SAFE_GETTEXT_DLL_OBJ = $(GETTEXT)/src/safe_gettext_dll/safe_gettext_dll.o
153# Alternatively, if you uncomment the two following lines, you get a "safe" version
154# without linking the safe_gettext_dll.o object file.
155#DYNAMIC_GETTEXT=DYNAMIC_GETTEXT
156#GETTEXT_DYNAMIC=gnu_gettext.dll
157INTLPATH=$(GETTEXT)/lib/mingw32
158INTLLIB=gnu_gettext
159
160# If you are using gettext-0.10.35 from http://sourceforge.net/projects/gettext
161# or gettext-0.10.37 from http://sourceforge.net/projects/mingwrep/
162# uncomment the following, but I can't build a static version with them, ?-(|
163#GETTEXT=c:/gettext-0.10.37-20010430
164#STATIC_GETTEXT=USE_STATIC_GETTEXT
165#DYNAMIC_GETTEXT=DYNAMIC_GETTEXT
166#INTLPATH=$(GETTEXT)/lib
167#INTLLIB=intl
168
Bram Moolenaare0485392016-07-12 21:17:03 +0200169
170# Command definitions (depends on cross-compiling and shell)
171ifeq ($(CROSS),yes)
172# cross-compiler prefix:
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200173 ifndef CROSS_COMPILE
Bram Moolenaare0485392016-07-12 21:17:03 +0200174CROSS_COMPILE = i586-pc-mingw32msvc-
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200175 endif
Bram Moolenaare0485392016-07-12 21:17:03 +0200176DEL = rm
177MKDIR = mkdir -p
178DIRSLASH = /
179else
180# normal (Windows) compilation:
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200181 ifndef CROSS_COMPILE
Bram Moolenaare0485392016-07-12 21:17:03 +0200182CROSS_COMPILE =
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200183 endif
Bram Moolenaare828b762018-09-10 17:51:58 +0200184
185# About the "sh.exe" condition, as explained by Ken Takata:
186#
187# If the makefile is executed with mingw32-make and sh.exe is not found in
188# $PATH, then $SHELL is set to "sh.exe" (without any path). In this case,
189# unix-like commands might not work and a dos-style path is needed.
190#
191# If the makefile is executed with mingw32-make and sh.exe IS found in $PATH,
192# then $SHELL is set with the actual path of sh.exe (e.g.
193# "C:/msys64/usr/bin/sh.exe"). In this case, unix-like commands can be used.
194#
195# If it is executed by the "make" command from cmd.exe, $SHELL is set to
196# "/bin/sh". If the "make" command is in the $PATH, other unix-like commands
197# might also work.
198#
199# If it is executed by the "make" command from a unix-like shell,
200# $SHELL is set with the unix-style path (e.g. "/bin/bash").
201# In this case, unix-like commands can be used.
202#
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200203 ifneq (sh.exe, $(SHELL))
Bram Moolenaare0485392016-07-12 21:17:03 +0200204DEL = rm
205MKDIR = mkdir -p
206DIRSLASH = /
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200207 else
Bram Moolenaare0485392016-07-12 21:17:03 +0200208DEL = del
209MKDIR = mkdir
210DIRSLASH = \\
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200211 endif
Bram Moolenaare0485392016-07-12 21:17:03 +0200212endif
213CC := $(CROSS_COMPILE)gcc
214CXX := $(CROSS_COMPILE)g++
215ifeq ($(UNDER_CYGWIN),yes)
216WINDRES := $(CROSS_COMPILE)windres
217else
218WINDRES := windres
219endif
220WINDRES_CC = $(CC)
221
222# Get the default ARCH.
223ifndef ARCH
Bram Moolenaarf62e7972016-07-14 20:25:03 +0200224ARCH := $(shell $(CC) -dumpmachine | sed -e 's/-.*//' -e 's/_/-/' -e 's/^mingw32$$/i686/')
Bram Moolenaare0485392016-07-12 21:17:03 +0200225endif
226
227
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100228# Perl interface:
229# PERL=[Path to Perl directory] (Set inside Make_cyg.mak or Make_ming.mak)
230# DYNAMIC_PERL=yes (to load the Perl DLL dynamically)
Bram Moolenaar0eaadec2016-09-08 20:28:45 +0200231# PERL_VER=[Perl version, eg 56, 58, 510] (default is 524)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100232ifdef PERL
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200233 ifndef PERL_VER
Bram Moolenaar0eaadec2016-09-08 20:28:45 +0200234PERL_VER=524
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200235 endif
236 ifndef DYNAMIC_PERL
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100237DYNAMIC_PERL=yes
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200238 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100239# on Linux, for cross-compile, it's here:
240#PERLLIB=/home/ron/ActivePerl/lib
241# on NT, it's here:
242PERLEXE=$(PERL)/bin/perl
243PERLLIB=$(PERL)/lib
244PERLLIBS=$(PERLLIB)/Core
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200245 ifeq ($(UNDER_CYGWIN),yes)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100246PERLTYPEMAP:=$(shell cygpath -m $(PERLLIB)/ExtUtils/typemap)
247XSUBPPTRY:=$(shell cygpath -m $(PERLLIB)/ExtUtils/xsubpp)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200248 else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100249PERLTYPEMAP=$(PERLLIB)/ExtUtils/typemap
250XSUBPPTRY=$(PERLLIB)/ExtUtils/xsubpp
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200251 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100252XSUBPP_EXISTS=$(shell $(PERLEXE) -e "print 1 unless -e '$(XSUBPPTRY)'")
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200253 ifeq "$(XSUBPP_EXISTS)" ""
Bram Moolenaar345326a2014-11-06 10:03:01 +0100254XSUBPP=$(PERLEXE) $(XSUBPPTRY)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200255 else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100256XSUBPP=xsubpp
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200257 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100258endif
259
260# Lua interface:
261# LUA=[Path to Lua directory] (Set inside Make_cyg.mak or Make_ming.mak)
Bram Moolenaarb872e632018-09-21 13:44:09 +0200262# LUA_LIBDIR=[Path to Lua library directory] (default: $LUA/lib)
263# LUA_INCDIR=[Path to Lua include directory] (default: $LUA/include)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100264# DYNAMIC_LUA=yes (to load the Lua DLL dynamically)
Bram Moolenaar0eaadec2016-09-08 20:28:45 +0200265# LUA_VER=[Lua version, eg 51, 52] (default is 53)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100266ifdef LUA
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200267 ifndef DYNAMIC_LUA
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100268DYNAMIC_LUA=yes
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200269 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100270
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200271 ifndef LUA_VER
Bram Moolenaar0eaadec2016-09-08 20:28:45 +0200272LUA_VER=53
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200273 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100274
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200275 ifeq (no,$(DYNAMIC_LUA))
Bram Moolenaarb872e632018-09-21 13:44:09 +0200276LUA_LIBDIR = $(LUA)/lib
277LUA_LIB = -L$(LUA_LIBDIR) -llua
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200278 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100279
280endif
281
282# MzScheme interface:
283# MZSCHEME=[Path to MzScheme directory] (Set inside Make_cyg.mak or Make_ming.mak)
284# DYNAMIC_MZSCHEME=yes (to load the MzScheme DLL dynamically)
Bram Moolenaar0eaadec2016-09-08 20:28:45 +0200285# MZSCHEME_VER=[MzScheme version] (default is 3m_a0solc (6.6))
Bram Moolenaarf16c71b2017-09-18 20:01:02 +0200286# Used for the DLL file name. E.g.:
287# C:\Program Files (x86)\Racket\lib\libracket3m_XXXXXX.dll
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100288# MZSCHEME_DEBUG=no
289ifdef MZSCHEME
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200290 ifndef DYNAMIC_MZSCHEME
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100291DYNAMIC_MZSCHEME=yes
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200292 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100293
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200294 ifndef MZSCHEME_VER
Bram Moolenaar0eaadec2016-09-08 20:28:45 +0200295MZSCHEME_VER=3m_a0solc
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200296 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100297
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100298# for version 4.x we need to generate byte-code for Scheme base
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200299 ifndef MZSCHEME_GENERATE_BASE
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100300MZSCHEME_GENERATE_BASE=no
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200301 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100302
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200303 ifneq ($(wildcard $(MZSCHEME)/lib/msvc/libmzsch$(MZSCHEME_VER).lib),)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100304MZSCHEME_MAIN_LIB=mzsch
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200305 else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100306MZSCHEME_MAIN_LIB=racket
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200307 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100308
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200309 ifndef MZSCHEME_PRECISE_GC
Bram Moolenaar4e640bd2016-01-16 16:20:38 +0100310MZSCHEME_PRECISE_GC=no
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200311 ifneq ($(wildcard $(MZSCHEME)\lib\lib$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER).dll),)
312 ifeq ($(wildcard $(MZSCHEME)\lib\libmzgc$(MZSCHEME_VER).dll),)
Bram Moolenaar4e640bd2016-01-16 16:20:38 +0100313MZSCHEME_PRECISE_GC=yes
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200314 endif
315 else
316 ifneq ($(wildcard $(MZSCHEME)\lib\msvc\lib$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER).lib),)
317 ifeq ($(wildcard $(MZSCHEME)\lib\msvc\libmzgc$(MZSCHEME_VER).lib),)
Bram Moolenaar4e640bd2016-01-16 16:20:38 +0100318MZSCHEME_PRECISE_GC=yes
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200319 endif
320 endif
321 endif
322 endif
Bram Moolenaar4e640bd2016-01-16 16:20:38 +0100323
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200324 ifeq (no,$(DYNAMIC_MZSCHEME))
325 ifeq (yes,$(MZSCHEME_PRECISE_GC))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100326MZSCHEME_LIB=-l$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200327 else
Bram Moolenaar4e640bd2016-01-16 16:20:38 +0100328MZSCHEME_LIB=-l$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER) -lmzgc$(MZSCHEME_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200329 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100330# the modern MinGW can dynamically link to dlls directly.
331# point MZSCHEME_DLLS to where you put libmzschXXXXXXX.dll and libgcXXXXXXX.dll
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200332 ifndef MZSCHEME_DLLS
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100333MZSCHEME_DLLS=$(MZSCHEME)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200334 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100335MZSCHEME_LIBDIR=-L$(MZSCHEME_DLLS) -L$(MZSCHEME_DLLS)\lib
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200336 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100337
338endif
339
340# Python interface:
341# PYTHON=[Path to Python directory] (Set inside Make_cyg.mak or Make_ming.mak)
342# DYNAMIC_PYTHON=yes (to load the Python DLL dynamically)
Bram Moolenaar0eaadec2016-09-08 20:28:45 +0200343# PYTHON_VER=[Python version, eg 22, 23, ..., 27] (default is 27)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100344ifdef PYTHON
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200345 ifndef DYNAMIC_PYTHON
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100346DYNAMIC_PYTHON=yes
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200347 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100348
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200349 ifndef PYTHON_VER
Bram Moolenaar3c6f92e2016-01-02 20:26:36 +0100350PYTHON_VER=27
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200351 endif
352 ifndef DYNAMIC_PYTHON_DLL
Bram Moolenaar3c6f92e2016-01-02 20:26:36 +0100353DYNAMIC_PYTHON_DLL=python$(PYTHON_VER).dll
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200354 endif
355 ifdef PYTHON_HOME
Bram Moolenaar3c6f92e2016-01-02 20:26:36 +0100356PYTHON_HOME_DEF=-DPYTHON_HOME=\"$(PYTHON_HOME)\"
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200357 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100358
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200359 ifeq (no,$(DYNAMIC_PYTHON))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100360PYTHONLIB=-L$(PYTHON)/libs -lpython$(PYTHON_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200361 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100362# my include files are in 'win32inc' on Linux, and 'include' in the standard
363# NT distro (ActiveState)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200364 ifndef PYTHONINC
365 ifeq ($(CROSS),no)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100366PYTHONINC=-I $(PYTHON)/include
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200367 else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100368PYTHONINC=-I $(PYTHON)/win32inc
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200369 endif
370 endif
Bram Moolenaar3c6f92e2016-01-02 20:26:36 +0100371endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100372
373# Python3 interface:
374# PYTHON3=[Path to Python3 directory] (Set inside Make_cyg.mak or Make_ming.mak)
375# DYNAMIC_PYTHON3=yes (to load the Python3 DLL dynamically)
Bram Moolenaar59eb0162017-12-10 18:17:44 +0100376# PYTHON3_VER=[Python3 version, eg 31, 32] (default is 36)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100377ifdef PYTHON3
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200378 ifndef DYNAMIC_PYTHON3
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100379DYNAMIC_PYTHON3=yes
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200380 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100381
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200382 ifndef PYTHON3_VER
Bram Moolenaar59eb0162017-12-10 18:17:44 +0100383PYTHON3_VER=36
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200384 endif
385 ifndef DYNAMIC_PYTHON3_DLL
Bram Moolenaara7c37952016-01-20 22:23:15 +0100386DYNAMIC_PYTHON3_DLL=python$(PYTHON3_VER).dll
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200387 endif
388 ifdef PYTHON3_HOME
Bram Moolenaaracd58ef2016-02-16 13:42:24 +0100389PYTHON3_HOME_DEF=-DPYTHON3_HOME=L\"$(PYTHON3_HOME)\"
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200390 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100391
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200392 ifeq (no,$(DYNAMIC_PYTHON3))
Bram Moolenaara7c37952016-01-20 22:23:15 +0100393PYTHON3LIB=-L$(PYTHON3)/libs -lpython$(PYTHON3_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200394 endif
Bram Moolenaara7c37952016-01-20 22:23:15 +0100395
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200396 ifndef PYTHON3INC
397 ifeq ($(CROSS),no)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100398PYTHON3INC=-I $(PYTHON3)/include
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200399 else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100400PYTHON3INC=-I $(PYTHON3)/win32inc
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200401 endif
402 endif
Bram Moolenaara7c37952016-01-20 22:23:15 +0100403endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100404
405# TCL interface:
406# TCL=[Path to TCL directory] (Set inside Make_cyg.mak or Make_ming.mak)
407# DYNAMIC_TCL=yes (to load the TCL DLL dynamically)
Bram Moolenaar0eaadec2016-09-08 20:28:45 +0200408# TCL_VER=[TCL version, eg 83, 84] (default is 86)
409# TCL_VER_LONG=[Tcl version, eg 8.3] (default is 8.6)
Bram Moolenaareca99bd2016-01-07 22:50:05 +0100410# You must set TCL_VER_LONG when you set TCL_VER.
Bram Moolenaar77f74742017-08-23 22:40:41 +0200411# TCL_DLL=[TCL dll name, eg tcl86.dll] (default is tcl86.dll)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100412ifdef TCL
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200413 ifndef DYNAMIC_TCL
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100414DYNAMIC_TCL=yes
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200415 endif
416 ifndef TCL_VER
Bram Moolenaar0eaadec2016-09-08 20:28:45 +0200417TCL_VER = 86
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200418 endif
419 ifndef TCL_VER_LONG
Bram Moolenaar0eaadec2016-09-08 20:28:45 +0200420TCL_VER_LONG = 8.6
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200421 endif
422 ifndef TCL_DLL
Bram Moolenaar77f74742017-08-23 22:40:41 +0200423TCL_DLL = tcl$(TCL_VER).dll
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200424 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100425TCLINC += -I$(TCL)/include
426endif
427
428
429# Ruby interface:
430# RUBY=[Path to Ruby directory] (Set inside Make_cyg.mak or Make_ming.mak)
Bram Moolenaar61766972018-04-20 22:31:41 +0200431# DYNAMIC_RUBY=yes (to load the Ruby DLL dynamically, "no" for static)
Bram Moolenaar6384c5d2016-09-06 22:06:35 +0200432# RUBY_VER=[Ruby version, eg 19, 22] (default is 22)
433# RUBY_API_VER_LONG=[Ruby API version, eg 1.8, 1.9.1, 2.2.0]
434# (default is 2.2.0)
435# You must set RUBY_API_VER_LONG when changing RUBY_VER.
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100436# Note: If you use Ruby 1.9.3, set as follows:
437# RUBY_VER=19
Bram Moolenaar6384c5d2016-09-06 22:06:35 +0200438# RUBY_API_VER_LONG=1.9.1 (not 1.9.3, because the API version is 1.9.1.)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100439ifdef RUBY
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200440 ifndef DYNAMIC_RUBY
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100441DYNAMIC_RUBY=yes
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200442 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100443# Set default value
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200444 ifndef RUBY_VER
Bram Moolenaar6384c5d2016-09-06 22:06:35 +0200445RUBY_VER = 22
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200446 endif
447 ifndef RUBY_VER_LONG
Bram Moolenaar6384c5d2016-09-06 22:06:35 +0200448RUBY_VER_LONG = 2.2.0
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200449 endif
450 ifndef RUBY_API_VER_LONG
Bram Moolenaar0eaadec2016-09-08 20:28:45 +0200451RUBY_API_VER_LONG = $(RUBY_VER_LONG)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200452 endif
453 ifndef RUBY_API_VER
Bram Moolenaar6384c5d2016-09-06 22:06:35 +0200454RUBY_API_VER = $(subst .,,$(RUBY_API_VER_LONG))
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200455 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100456
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200457 ifndef RUBY_PLATFORM
458 ifeq ($(RUBY_VER), 16)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100459RUBY_PLATFORM = i586-mswin32
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200460 else ifneq ($(wildcard $(RUBY)/lib/ruby/$(RUBY_API_VER_LONG)/i386-mingw32),)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100461RUBY_PLATFORM = i386-mingw32
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200462 else ifneq ($(wildcard $(RUBY)/lib/ruby/$(RUBY_API_VER_LONG)/x64-mingw32),)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100463RUBY_PLATFORM = x64-mingw32
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200464 else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100465RUBY_PLATFORM = i386-mswin32
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200466 endif
467 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100468
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200469 ifndef RUBY_INSTALL_NAME
470 ifeq ($(RUBY_VER), 16)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100471RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_API_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200472 else
473 ifndef RUBY_MSVCRT_NAME
Bram Moolenaar0bee2fe2016-01-07 22:45:09 +0100474# Base name of msvcrXX.dll which is used by ruby's dll.
475RUBY_MSVCRT_NAME = msvcrt
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200476 endif
477 ifeq ($(ARCH),x86-64)
Bram Moolenaar0bee2fe2016-01-07 22:45:09 +0100478RUBY_INSTALL_NAME = x64-$(RUBY_MSVCRT_NAME)-ruby$(RUBY_API_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200479 else
Bram Moolenaar0bee2fe2016-01-07 22:45:09 +0100480RUBY_INSTALL_NAME = $(RUBY_MSVCRT_NAME)-ruby$(RUBY_API_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200481 endif
482 endif
483 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100484
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200485 ifeq (19, $(word 1,$(sort 19 $(RUBY_VER))))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100486RUBY_19_OR_LATER = 1
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200487 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100488
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200489 ifdef RUBY_19_OR_LATER
Bram Moolenaar76c612a2018-09-21 14:31:51 +0200490RUBYINC = -I $(RUBY)/include/ruby-$(RUBY_API_VER_LONG) -I $(RUBY)/include/ruby-$(RUBY_API_VER_LONG)/$(RUBY_PLATFORM)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200491 else
Bram Moolenaar76c612a2018-09-21 14:31:51 +0200492RUBYINC = -I $(RUBY)/lib/ruby/$(RUBY_API_VER_LONG)/$(RUBY_PLATFORM)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200493 endif
494 ifeq (no, $(DYNAMIC_RUBY))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100495RUBYLIB = -L$(RUBY)/lib -l$(RUBY_INSTALL_NAME)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200496 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100497
498endif # RUBY
499
500# See feature.h for a list of options.
501# Any other defines can be included here.
Bram Moolenaar0472b6d2019-02-18 21:41:37 +0100502DEF_GUI=-DFEAT_GUI_MSWIN -DFEAT_CLIPBOARD
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100503DEFINES=-DWIN32 -DWINVER=$(WINVER) -D_WIN32_WINNT=$(WINVER) \
Bram Moolenaar22fcfad2016-07-01 18:17:26 +0200504 -DHAVE_PATHDEF -DFEAT_$(FEATURES) -DHAVE_STDINT_H
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100505ifeq ($(ARCH),x86-64)
506DEFINES+=-DMS_WIN64
507endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100508
509#>>>>> end of choices
510###########################################################################
511
Bram Moolenaarb361db02018-10-16 21:13:14 +0200512CFLAGS = -I. -Iproto $(DEFINES) -pipe -march=$(ARCH) -Wall
Bram Moolenaar6c0e9842016-03-22 20:42:31 +0100513CXXFLAGS = -std=gnu++11
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100514WINDRES_FLAGS = --preprocessor="$(WINDRES_CC) -E -xc" -DRC_INVOKED
515EXTRA_LIBS =
516
517ifdef GETTEXT
518DEFINES += -DHAVE_GETTEXT -DHAVE_LOCALE_H
519GETTEXTINCLUDE = $(GETTEXT)/include
520GETTEXTLIB = $(INTLPATH)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200521 ifeq (yes, $(GETTEXT))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100522DEFINES += -DDYNAMIC_GETTEXT
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200523 else ifdef DYNAMIC_GETTEXT
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100524DEFINES += -D$(DYNAMIC_GETTEXT)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200525 ifdef GETTEXT_DYNAMIC
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100526DEFINES += -DGETTEXT_DYNAMIC -DGETTEXT_DLL=\"$(GETTEXT_DYNAMIC)\"
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200527 endif
528 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100529endif
530
531ifdef PERL
Bram Moolenaar367fbf12015-06-25 16:13:46 +0200532CFLAGS += -I$(PERLLIBS) -DFEAT_PERL -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200533 ifeq (yes, $(DYNAMIC_PERL))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100534CFLAGS += -DDYNAMIC_PERL -DDYNAMIC_PERL_DLL=\"perl$(PERL_VER).dll\"
535EXTRA_LIBS += -L$(PERLLIBS) -lperl$(PERL_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200536 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100537endif
538
539ifdef LUA
Bram Moolenaarb872e632018-09-21 13:44:09 +0200540LUA_INCDIR = $(LUA)/include
541CFLAGS += -I$(LUA_INCDIR) -I$(LUA) -DFEAT_LUA
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200542 ifeq (yes, $(DYNAMIC_LUA))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100543CFLAGS += -DDYNAMIC_LUA -DDYNAMIC_LUA_DLL=\"lua$(LUA_VER).dll\"
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200544 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100545endif
546
547ifdef MZSCHEME
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200548 ifndef MZSCHEME_COLLECTS
Bram Moolenaar4e640bd2016-01-16 16:20:38 +0100549MZSCHEME_COLLECTS=$(MZSCHEME)/collects
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200550 ifeq (yes, $(UNDER_CYGWIN))
Bram Moolenaar4e640bd2016-01-16 16:20:38 +0100551MZSCHEME_COLLECTS:=$(shell cygpath -m $(MZSCHEME_COLLECTS) | sed -e 's/ /\\ /g')
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200552 endif
553 endif
Bram Moolenaar4e640bd2016-01-16 16:20:38 +0100554CFLAGS += -I$(MZSCHEME)/include -DFEAT_MZSCHEME -DMZSCHEME_COLLECTS=\"$(MZSCHEME_COLLECTS)\"
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200555 ifeq (yes, $(DYNAMIC_MZSCHEME))
556 ifeq (yes, $(MZSCHEME_PRECISE_GC))
Bram Moolenaar4e640bd2016-01-16 16:20:38 +0100557# Precise GC does not use separate dll
558CFLAGS += -DDYNAMIC_MZSCHEME -DDYNAMIC_MZSCH_DLL=\"lib$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER).dll\" -DDYNAMIC_MZGC_DLL=\"lib$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER).dll\"
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200559 else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100560CFLAGS += -DDYNAMIC_MZSCHEME -DDYNAMIC_MZSCH_DLL=\"lib$(MZSCHEME_MAIN_LIB)$(MZSCHEME_VER).dll\" -DDYNAMIC_MZGC_DLL=\"libmzgc$(MZSCHEME_VER).dll\"
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200561 endif
562 endif
563 ifeq (yes, "$(MZSCHEME_DEBUG)")
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100564CFLAGS += -DMZSCHEME_FORCE_GC
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200565 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100566endif
567
568ifdef RUBY
569CFLAGS += -DFEAT_RUBY $(RUBYINC)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200570 ifeq (yes, $(DYNAMIC_RUBY))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100571CFLAGS += -DDYNAMIC_RUBY -DDYNAMIC_RUBY_DLL=\"$(RUBY_INSTALL_NAME).dll\"
572CFLAGS += -DDYNAMIC_RUBY_VER=$(RUBY_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200573 endif
574 ifeq (no, $(DYNAMIC_RUBY))
Bram Moolenaar259a90f2018-04-21 19:08:55 +0200575CFLAGS += -DRUBY_VERSION=$(RUBY_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200576 endif
577 ifneq ($(findstring w64-mingw32,$(CC)),)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100578# A workaround for MinGW-w64
579CFLAGS += -DHAVE_STRUCT_TIMESPEC -DHAVE_STRUCT_TIMEZONE
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200580 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100581endif
582
583ifdef PYTHON
Bram Moolenaar223b7232016-02-19 19:43:49 +0100584CFLAGS += -DFEAT_PYTHON
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200585 ifeq (yes, $(DYNAMIC_PYTHON))
Bram Moolenaar449538c2016-01-09 17:49:15 +0100586CFLAGS += -DDYNAMIC_PYTHON -DDYNAMIC_PYTHON_DLL=\"$(DYNAMIC_PYTHON_DLL)\"
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200587 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100588endif
589
Bram Moolenaar223b7232016-02-19 19:43:49 +0100590ifdef PYTHON3
591CFLAGS += -DFEAT_PYTHON3
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200592 ifeq (yes, $(DYNAMIC_PYTHON3))
Bram Moolenaara7c37952016-01-20 22:23:15 +0100593CFLAGS += -DDYNAMIC_PYTHON3 -DDYNAMIC_PYTHON3_DLL=\"$(DYNAMIC_PYTHON3_DLL)\"
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200594 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100595endif
596
597ifdef TCL
598CFLAGS += -DFEAT_TCL $(TCLINC)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200599 ifeq (yes, $(DYNAMIC_TCL))
Bram Moolenaar77f74742017-08-23 22:40:41 +0200600CFLAGS += -DDYNAMIC_TCL -DDYNAMIC_TCL_DLL=\"$(TCL_DLL)\" -DDYNAMIC_TCL_VER=\"$(TCL_VER_LONG)\"
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200601 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100602endif
603
604ifeq ($(POSTSCRIPT),yes)
605DEFINES += -DMSWINPS
606endif
607
608ifeq (yes, $(OLE))
609DEFINES += -DFEAT_OLE
610endif
611
612ifeq ($(CSCOPE),yes)
613DEFINES += -DFEAT_CSCOPE
614endif
615
616ifeq ($(NETBEANS),yes)
617# Only allow NETBEANS for a GUI build.
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200618 ifeq (yes, $(GUI))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100619DEFINES += -DFEAT_NETBEANS_INTG
620
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200621 ifeq ($(NBDEBUG), yes)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100622DEFINES += -DNBDEBUG
623NBDEBUG_INCL = nbdebug.h
624NBDEBUG_SRC = nbdebug.c
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200625 endif
626 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100627endif
628
Bram Moolenaare0874f82016-01-24 20:36:41 +0100629ifeq ($(CHANNEL),yes)
Bram Moolenaar509ce2a2016-03-11 22:52:15 +0100630DEFINES += -DFEAT_JOB_CHANNEL
Bram Moolenaare0874f82016-01-24 20:36:41 +0100631endif
632
Bram Moolenaar4fc63502017-07-19 11:28:17 +0200633ifeq ($(TERMINAL),yes)
634DEFINES += -DFEAT_TERMINAL
Bram Moolenaarf80451e2017-07-25 21:49:35 +0200635TERM_DEPS = \
636 libvterm/include/vterm.h \
637 libvterm/include/vterm_keycodes.h \
638 libvterm/src/rect.h \
639 libvterm/src/utf8.h \
640 libvterm/src/vterm_internal.h
Bram Moolenaar4fc63502017-07-19 11:28:17 +0200641endif
642
Bram Moolenaar9b283522019-06-17 22:19:33 +0200643ifeq ($(SOUND),yes)
644DEFINES += -DFEAT_SOUND
645endif
646
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100647# DirectWrite (DirectX)
648ifeq ($(DIRECTX),yes)
649# Only allow DirectWrite for a GUI build.
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200650 ifeq (yes, $(GUI))
Bram Moolenaarcccd62d2018-04-12 20:23:48 +0200651DEFINES += -DFEAT_DIRECTX -DDYNAMIC_DIRECTX
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200652 ifneq ($(COLOR_EMOJI),no)
Bram Moolenaarcccd62d2018-04-12 20:23:48 +0200653DEFINES += -DFEAT_DIRECTX_COLOR_EMOJI
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200654 endif
655 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100656endif
657
658# Only allow XPM for a GUI build.
659ifeq (yes, $(GUI))
660
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200661 ifndef XPM
662 ifeq ($(ARCH),i386)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100663XPM = xpm/x86
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200664 endif
665 ifeq ($(ARCH),i486)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100666XPM = xpm/x86
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200667 endif
668 ifeq ($(ARCH),i586)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100669XPM = xpm/x86
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200670 endif
671 ifeq ($(ARCH),i686)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100672XPM = xpm/x86
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200673 endif
674 ifeq ($(ARCH),x86-64)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100675XPM = xpm/x64
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200676 endif
677 endif
678 ifdef XPM
679 ifneq ($(XPM),no)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100680CFLAGS += -DFEAT_XPM_W32 -I $(XPM)/include -I $(XPM)/../include
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200681 endif
682 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100683
684endif
685
686ifeq ($(DEBUG),yes)
687CFLAGS += -g -fstack-check
688DEBUG_SUFFIX=d
689else
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200690 ifeq ($(OPTIMIZE), SIZE)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100691CFLAGS += -Os
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200692 else ifeq ($(OPTIMIZE), MAXSPEED)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100693CFLAGS += -O3
694CFLAGS += -fomit-frame-pointer -freg-struct-return
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200695 else # SPEED
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100696CFLAGS += -O2
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200697 endif
Bram Moolenaarafde13b2019-04-28 19:46:49 +0200698LFLAGS += -s
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100699endif
700
Bram Moolenaar828c3d72018-06-19 18:58:07 +0200701LIB = -lkernel32 -luser32 -lgdi32 -ladvapi32 -lcomdlg32 -lcomctl32 -lnetapi32 -lversion
Bram Moolenaar796cc422019-04-03 20:31:00 +0200702GUIOBJ = $(OUTDIR)/gui.o $(OUTDIR)/gui_w32.o $(OUTDIR)/gui_beval.o
Bram Moolenaar97ff9b92016-06-26 20:37:46 +0200703CUIOBJ = $(OUTDIR)/iscygpty.o
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100704OBJ = \
Bram Moolenaar75464dc2016-07-02 20:27:50 +0200705 $(OUTDIR)/arabic.o \
Bram Moolenaar3e460fd2019-01-26 16:21:07 +0100706 $(OUTDIR)/autocmd.o \
Bram Moolenaarc3719bd2017-11-18 22:13:31 +0100707 $(OUTDIR)/beval.o \
Bram Moolenaar6e5ea8d2019-01-12 22:47:31 +0100708 $(OUTDIR)/blob.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100709 $(OUTDIR)/blowfish.o \
710 $(OUTDIR)/buffer.o \
Bram Moolenaarec28d152019-05-11 18:36:34 +0200711 $(OUTDIR)/change.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100712 $(OUTDIR)/charset.o \
713 $(OUTDIR)/crypt.o \
714 $(OUTDIR)/crypt_zip.o \
Bram Moolenaareead75c2019-04-21 11:35:00 +0200715 $(OUTDIR)/debugger.o \
Bram Moolenaar6583c442016-07-17 18:41:47 +0200716 $(OUTDIR)/dict.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100717 $(OUTDIR)/diff.o \
718 $(OUTDIR)/digraph.o \
719 $(OUTDIR)/edit.o \
720 $(OUTDIR)/eval.o \
Bram Moolenaar73dad1e2016-07-17 22:13:49 +0200721 $(OUTDIR)/evalfunc.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100722 $(OUTDIR)/ex_cmds.o \
723 $(OUTDIR)/ex_cmds2.o \
724 $(OUTDIR)/ex_docmd.o \
725 $(OUTDIR)/ex_eval.o \
726 $(OUTDIR)/ex_getln.o \
727 $(OUTDIR)/fileio.o \
Bram Moolenaar5fd0f502019-02-13 23:13:28 +0100728 $(OUTDIR)/findfile.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100729 $(OUTDIR)/fold.o \
730 $(OUTDIR)/getchar.o \
731 $(OUTDIR)/hardcopy.o \
732 $(OUTDIR)/hashtab.o \
Bram Moolenaar4b471622019-01-31 13:48:09 +0100733 $(OUTDIR)/indent.o \
Bram Moolenaar7591bb32019-03-30 13:53:47 +0100734 $(OUTDIR)/insexpand.o \
Bram Moolenaar520e1e42016-01-23 19:46:28 +0100735 $(OUTDIR)/json.o \
Bram Moolenaar6583c442016-07-17 18:41:47 +0200736 $(OUTDIR)/list.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100737 $(OUTDIR)/main.o \
738 $(OUTDIR)/mark.o \
739 $(OUTDIR)/memfile.o \
740 $(OUTDIR)/memline.o \
741 $(OUTDIR)/menu.o \
742 $(OUTDIR)/message.o \
743 $(OUTDIR)/misc1.o \
744 $(OUTDIR)/misc2.o \
745 $(OUTDIR)/move.o \
746 $(OUTDIR)/mbyte.o \
747 $(OUTDIR)/normal.o \
748 $(OUTDIR)/ops.o \
749 $(OUTDIR)/option.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100750 $(OUTDIR)/os_mswin.o \
Bram Moolenaar796cc422019-04-03 20:31:00 +0200751 $(OUTDIR)/os_win32.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100752 $(OUTDIR)/pathdef.o \
753 $(OUTDIR)/popupmnu.o \
Bram Moolenaar4d784b22019-05-25 19:51:39 +0200754 $(OUTDIR)/popupwin.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100755 $(OUTDIR)/quickfix.o \
756 $(OUTDIR)/regexp.o \
757 $(OUTDIR)/screen.o \
758 $(OUTDIR)/search.o \
759 $(OUTDIR)/sha256.o \
Bram Moolenaarbbea4702019-01-01 13:20:31 +0100760 $(OUTDIR)/sign.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100761 $(OUTDIR)/spell.o \
Bram Moolenaar9ccfebd2016-07-19 16:39:08 +0200762 $(OUTDIR)/spellfile.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100763 $(OUTDIR)/syntax.o \
764 $(OUTDIR)/tag.o \
765 $(OUTDIR)/term.o \
Bram Moolenaar98aefe72018-12-13 22:20:09 +0100766 $(OUTDIR)/textprop.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100767 $(OUTDIR)/ui.o \
768 $(OUTDIR)/undo.o \
Bram Moolenaarac9fb182019-04-27 13:04:13 +0200769 $(OUTDIR)/usercmd.o \
Bram Moolenaar6583c442016-07-17 18:41:47 +0200770 $(OUTDIR)/userfunc.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100771 $(OUTDIR)/version.o \
Bram Moolenaar796cc422019-04-03 20:31:00 +0200772 $(OUTDIR)/winclip.o \
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100773 $(OUTDIR)/window.o
774
Bram Moolenaarafde13b2019-04-28 19:46:49 +0200775ifeq ($(VIMDLL),yes)
776OBJ += $(OUTDIR)/os_w32dll.o $(OUTDIR)/vimrcd.o
777EXEOBJC = $(OUTDIR)/os_w32exec.o $(OUTDIR)/vimrcc.o
778EXEOBJG = $(OUTDIR)/os_w32exeg.o $(OUTDIR)/vimrcg.o
779else
780OBJ += $(OUTDIR)/os_w32exe.o $(OUTDIR)/vimrc.o
781endif
782
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100783ifdef PERL
784OBJ += $(OUTDIR)/if_perl.o
785endif
786ifdef LUA
787OBJ += $(OUTDIR)/if_lua.o
788endif
789ifdef MZSCHEME
790OBJ += $(OUTDIR)/if_mzsch.o
791MZSCHEME_INCL = if_mzsch.h
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200792 ifeq (yes,$(MZSCHEME_GENERATE_BASE))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100793CFLAGS += -DINCLUDE_MZSCHEME_BASE
794MZ_EXTRA_DEP += mzscheme_base.c
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200795 endif
796 ifeq (yes,$(MZSCHEME_PRECISE_GC))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100797CFLAGS += -DMZ_PRECISE_GC
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200798 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100799endif
800ifdef PYTHON
801OBJ += $(OUTDIR)/if_python.o
802endif
803ifdef PYTHON3
804OBJ += $(OUTDIR)/if_python3.o
805endif
806ifdef RUBY
807OBJ += $(OUTDIR)/if_ruby.o
808endif
809ifdef TCL
810OBJ += $(OUTDIR)/if_tcl.o
811endif
812ifeq ($(CSCOPE),yes)
813OBJ += $(OUTDIR)/if_cscope.o
814endif
Bram Moolenaare0874f82016-01-24 20:36:41 +0100815
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100816ifeq ($(NETBEANS),yes)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200817 ifneq ($(CHANNEL),yes)
Bram Moolenaare0874f82016-01-24 20:36:41 +0100818# Cannot use Netbeans without CHANNEL
819NETBEANS=no
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200820 else ifneq (yes, $(GUI))
Bram Moolenaar44d57182016-02-14 23:11:23 +0100821# Cannot use Netbeans without GUI.
822NETBEANS=no
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200823 else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100824OBJ += $(OUTDIR)/netbeans.o
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200825 endif
Bram Moolenaare0874f82016-01-24 20:36:41 +0100826endif
827
828ifeq ($(CHANNEL),yes)
829OBJ += $(OUTDIR)/channel.o
Bram Moolenaare0874f82016-01-24 20:36:41 +0100830LIB += -lwsock32
831endif
Bram Moolenaare0874f82016-01-24 20:36:41 +0100832
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100833ifeq ($(DIRECTX),yes)
834# Only allow DIRECTX for a GUI build.
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200835 ifeq (yes, $(GUI))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100836OBJ += $(OUTDIR)/gui_dwrite.o
837LIB += -ld2d1 -ldwrite
838USE_STDCPLUS = yes
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200839 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100840endif
841ifneq ($(XPM),no)
842# Only allow XPM for a GUI build.
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200843 ifeq (yes, $(GUI))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100844OBJ += $(OUTDIR)/xpm_w32.o
845# You'll need libXpm.a from http://gnuwin32.sf.net
846LIB += -L$(XPM)/lib -lXpm
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200847 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100848endif
849
Bram Moolenaar4fc63502017-07-19 11:28:17 +0200850ifeq ($(TERMINAL),yes)
Bram Moolenaarf80451e2017-07-25 21:49:35 +0200851OBJ += $(OUTDIR)/terminal.o \
Bram Moolenaar78dcd4f2018-09-13 17:23:28 +0200852 $(OUTDIR)/encoding.o \
853 $(OUTDIR)/keyboard.o \
854 $(OUTDIR)/mouse.o \
855 $(OUTDIR)/parser.o \
856 $(OUTDIR)/pen.o \
857 $(OUTDIR)/termscreen.o \
858 $(OUTDIR)/state.o \
859 $(OUTDIR)/unicode.o \
860 $(OUTDIR)/vterm.o
Bram Moolenaar4fc63502017-07-19 11:28:17 +0200861endif
862
Bram Moolenaar9b283522019-06-17 22:19:33 +0200863ifeq ($(SOUND),yes)
864OBJ += $(OUTDIR)/sound.o
865endif
866
Bram Moolenaare828b762018-09-10 17:51:58 +0200867# Include xdiff
868OBJ += $(OUTDIR)/xdiffi.o \
869 $(OUTDIR)/xemit.o \
870 $(OUTDIR)/xprepare.o \
871 $(OUTDIR)/xutils.o \
872 $(OUTDIR)/xhistogram.o \
873 $(OUTDIR)/xpatience.o
874
875XDIFF_DEPS = \
876 xdiff/xdiff.h \
877 xdiff/xdiffi.h \
878 xdiff/xemit.h \
879 xdiff/xinclude.h \
880 xdiff/xmacros.h \
881 xdiff/xprepare.h \
882 xdiff/xtypes.h \
883 xdiff/xutils.h
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100884
885ifdef MZSCHEME
886MZSCHEME_SUFFIX = Z
887endif
888
Bram Moolenaar796cc422019-04-03 20:31:00 +0200889LFLAGS += -municode
890
Bram Moolenaarafde13b2019-04-28 19:46:49 +0200891ifeq ($(VIMDLL),yes)
892VIMEXE := vim$(DEBUG_SUFFIX).exe
893GVIMEXE := gvim$(DEBUG_SUFFIX).exe
894 ifeq ($(ARCH),x86-64)
895VIMDLLBASE := vim64$(DEBUG_SUFFIX)
896 else
897VIMDLLBASE := vim32$(DEBUG_SUFFIX)
898 endif
899TARGET = $(VIMDLLBASE).dll
900LFLAGS += -shared
901EXELFLAGS += -municode
902 ifneq ($(DEBUG),yes)
903EXELFLAGS += -s
904 endif
905DEFINES += $(DEF_GUI) -DVIMDLL
906OBJ += $(GUIOBJ) $(CUIOBJ)
907OUTDIR = dobj$(DEBUG_SUFFIX)$(MZSCHEME_SUFFIX)$(ARCH)
908MAIN_TARGET = $(GVIMEXE) $(VIMEXE) $(VIMDLLBASE).dll
909else ifeq ($(GUI),yes)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100910TARGET := gvim$(DEBUG_SUFFIX).exe
911DEFINES += $(DEF_GUI)
912OBJ += $(GUIOBJ)
913LFLAGS += -mwindows
914OUTDIR = gobj$(DEBUG_SUFFIX)$(MZSCHEME_SUFFIX)$(ARCH)
Bram Moolenaarafde13b2019-04-28 19:46:49 +0200915MAIN_TARGET = $(TARGET)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100916else
Bram Moolenaar97ff9b92016-06-26 20:37:46 +0200917OBJ += $(CUIOBJ)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100918TARGET := vim$(DEBUG_SUFFIX).exe
919OUTDIR = obj$(DEBUG_SUFFIX)$(MZSCHEME_SUFFIX)$(ARCH)
Bram Moolenaarafde13b2019-04-28 19:46:49 +0200920MAIN_TARGET = $(TARGET)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100921endif
922
923ifdef GETTEXT
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200924 ifneq (yes, $(GETTEXT))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100925CFLAGS += -I$(GETTEXTINCLUDE)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200926 ifndef STATIC_GETTEXT
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100927LIB += -L$(GETTEXTLIB) -l$(INTLLIB)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200928 ifeq (USE_SAFE_GETTEXT_DLL, $(DYNAMIC_GETTEXT))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100929OBJ+=$(SAFE_GETTEXT_DLL_OBJ)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200930 endif
931 else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100932LIB += -L$(GETTEXTLIB) -lintl
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200933 endif
934 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100935endif
936
937ifdef PERL
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200938 ifeq (no, $(DYNAMIC_PERL))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100939LIB += -L$(PERLLIBS) -lperl$(PERL_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200940 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100941endif
942
943ifdef TCL
944LIB += -L$(TCL)/lib
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200945 ifeq (yes, $(DYNAMIC_TCL))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100946LIB += -ltclstub$(TCL_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200947 else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100948LIB += -ltcl$(TCL_VER)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200949 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100950endif
951
952ifeq (yes, $(OLE))
953LIB += -loleaut32
954OBJ += $(OUTDIR)/if_ole.o
955USE_STDCPLUS = yes
956endif
957
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100958ifeq (yes, $(IME))
959DEFINES += -DFEAT_MBYTE_IME
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200960 ifeq (yes, $(DYNAMIC_IME))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100961DEFINES += -DDYNAMIC_IME
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200962 else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100963LIB += -limm32
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200964 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100965endif
966
967ifdef ICONV
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200968 ifneq (yes, $(ICONV))
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100969LIB += -L$(ICONV)
970CFLAGS += -I$(ICONV)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200971 endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100972DEFINES+=-DDYNAMIC_ICONV
973endif
974
Bram Moolenaar9b283522019-06-17 22:19:33 +0200975ifeq (yes, $(SOUND))
976LIB += -lwinmm
977endif
978
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100979ifeq (yes, $(USE_STDCPLUS))
Bram Moolenaareda9e9c2018-10-21 22:45:43 +0200980LINK = $(CXX)
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200981 ifeq (yes, $(STATIC_STDCPLUS))
Bram Moolenaar60f807b2019-01-31 14:43:19 +0100982#LIB += -static-libstdc++ -static-libgcc
Bram Moolenaard91e5da2019-02-21 13:34:07 +0100983LIB += -Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200984 endif
Bram Moolenaareda9e9c2018-10-21 22:45:43 +0200985else
986LINK = $(CC)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +0100987endif
988
Bram Moolenaare3af7632016-12-01 20:37:47 +0100989ifeq (yes, $(STATIC_WINPTHREAD))
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200990 ifeq (yes, $(HAS_GCC_EH))
Bram Moolenaareda9e9c2018-10-21 22:45:43 +0200991LIB += -lgcc_eh
Bram Moolenaar6e75e0a2019-05-11 21:24:26 +0200992 endif
Bram Moolenaare3af7632016-12-01 20:37:47 +0100993LIB += -Wl,-Bstatic -lwinpthread -Wl,-Bdynamic
994endif
995
Bram Moolenaar4ff42902018-09-21 14:43:10 +0200996ifeq (yes, $(MAP))
997LFLAGS += -Wl,-Map=$(TARGET).map
998endif
999
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001000all: $(MAIN_TARGET) vimrun.exe xxd/xxd.exe tee/tee.exe install.exe uninstal.exe GvimExt/gvimext.dll
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001001
1002vimrun.exe: vimrun.c
1003 $(CC) $(CFLAGS) -o vimrun.exe vimrun.c $(LIB)
1004
1005install.exe: dosinst.c
1006 $(CC) $(CFLAGS) -o install.exe dosinst.c $(LIB) -lole32 -luuid
1007
1008uninstal.exe: uninstal.c
Bram Moolenaare28cfb22019-07-11 22:04:21 +02001009 $(CC) $(CFLAGS) -o uninstal.exe uninstal.c $(LIB) -lole32
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001010
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001011ifeq ($(VIMDLL),yes)
1012$(TARGET): $(OUTDIR) $(OBJ)
1013 $(LINK) $(CFLAGS) $(LFLAGS) -o $@ $(OBJ) $(LIB) -lole32 -luuid -lgdi32 $(LUA_LIB) $(MZSCHEME_LIBDIR) $(MZSCHEME_LIB) $(PYTHONLIB) $(PYTHON3LIB) $(RUBYLIB)
1014
1015$(GVIMEXE): $(OUTDIR) $(EXEOBJG) $(VIMDLLBASE).dll
1016 $(CC) -L. $(EXELFLAGS) -mwindows -o $@ $(EXEOBJG) -l$(VIMDLLBASE)
1017
1018$(VIMEXE): $(OUTDIR) $(EXEOBJC) $(VIMDLLBASE).dll
1019 $(CC) -L. $(EXELFLAGS) -o $@ $(EXEOBJC) -l$(VIMDLLBASE)
1020else
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001021$(TARGET): $(OUTDIR) $(OBJ)
Bram Moolenaareda9e9c2018-10-21 22:45:43 +02001022 $(LINK) $(CFLAGS) $(LFLAGS) -o $@ $(OBJ) $(LIB) -lole32 -luuid $(LUA_LIB) $(MZSCHEME_LIBDIR) $(MZSCHEME_LIB) $(PYTHONLIB) $(PYTHON3LIB) $(RUBYLIB)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001023endif
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001024
1025upx: exes
1026 upx gvim.exe
1027 upx vim.exe
1028
1029mpress: exes
1030 mpress gvim.exe
1031 mpress vim.exe
1032
1033xxd/xxd.exe: xxd/xxd.c
1034 $(MAKE) -C xxd -f Make_ming.mak CC='$(CC)'
1035
Bram Moolenaar04c86d22018-10-17 22:45:54 +02001036tee/tee.exe: tee/tee.c
1037 $(MAKE) -C tee CC='$(CC)'
1038
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001039GvimExt/gvimext.dll: GvimExt/gvimext.cpp GvimExt/gvimext.rc GvimExt/gvimext.h
1040 $(MAKE) -C GvimExt -f Make_ming.mak CROSS=$(CROSS) CROSS_COMPILE=$(CROSS_COMPILE) CXX='$(CXX)' STATIC_STDCPLUS=$(STATIC_STDCPLUS)
1041
Bram Moolenaar9ac9dfa2017-09-01 18:41:26 +02001042tags: notags
Bram Moolenaar6dc67032018-12-19 21:05:57 +01001043 $(CTAGS) $(TAGS_FILES)
Bram Moolenaar9ac9dfa2017-09-01 18:41:26 +02001044
1045notags:
1046 -$(DEL) tags
1047
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001048clean:
1049 -$(DEL) $(OUTDIR)$(DIRSLASH)*.o
1050 -$(DEL) $(OUTDIR)$(DIRSLASH)*.res
Bram Moolenaardfc14552019-06-21 17:36:10 +02001051 -$(DEL) $(OUTDIR)$(DIRSLASH)pathdef.c
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001052 -rmdir $(OUTDIR)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001053 -$(DEL) $(MAIN_TARGET) vimrun.exe install.exe uninstal.exe
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001054ifdef PERL
1055 -$(DEL) if_perl.c
Bram Moolenaara16bc542018-10-14 16:25:10 +02001056 -$(DEL) auto$(DIRSLASH)if_perl.c
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001057endif
1058ifdef MZSCHEME
1059 -$(DEL) mzscheme_base.c
1060endif
1061 $(MAKE) -C GvimExt -f Make_ming.mak clean
1062 $(MAKE) -C xxd -f Make_ming.mak clean
Bram Moolenaar04c86d22018-10-17 22:45:54 +02001063 $(MAKE) -C tee clean
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001064
1065###########################################################################
Bram Moolenaare37368c2019-03-22 16:57:45 +01001066INCL = vim.h alloc.h ascii.h ex_cmds.h feature.h globals.h \
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001067 keymap.h macros.h option.h os_dos.h os_win32.h proto.h regexp.h \
Bram Moolenaarc3719bd2017-11-18 22:13:31 +01001068 spell.h structs.h term.h beval.h $(NBDEBUG_INCL)
1069GUI_INCL = gui.h
Bram Moolenaard22a6f82019-05-24 17:17:54 +02001070ifeq ($(DIRECTX),yes)
1071GUI_INCL += gui_dwrite.h
1072endif
Bram Moolenaar97ff9b92016-06-26 20:37:46 +02001073CUI_INCL = iscygpty.h
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001074
Bram Moolenaardfc14552019-06-21 17:36:10 +02001075PATHDEF_SRC = $(OUTDIR)/pathdef.c
1076
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001077$(OUTDIR)/if_python.o: if_python.c if_py_both.h $(INCL)
Bram Moolenaar449538c2016-01-09 17:49:15 +01001078 $(CC) -c $(CFLAGS) $(PYTHONINC) $(PYTHON_HOME_DEF) $< -o $@
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001079
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001080$(OUTDIR)/if_python3.o: if_python3.c if_py_both.h $(INCL)
Bram Moolenaara7c37952016-01-20 22:23:15 +01001081 $(CC) -c $(CFLAGS) $(PYTHON3INC) $(PYTHON3_HOME_DEF) $< -o $@
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001082
1083$(OUTDIR)/%.o : %.c $(INCL)
1084 $(CC) -c $(CFLAGS) $< -o $@
1085
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001086ifeq ($(VIMDLL),yes)
1087$(OUTDIR)/vimrcc.o: vim.rc gvim.exe.mnf version.h gui_w32_rc.h vim.ico
1088 $(WINDRES) $(WINDRES_FLAGS) $(DEFINES) -UFEAT_GUI_MSWIN \
1089 --input-format=rc --output-format=coff -i vim.rc -o $@
1090
1091$(OUTDIR)/vimrcg.o: vim.rc gvim.exe.mnf version.h gui_w32_rc.h vim.ico
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001092 $(WINDRES) $(WINDRES_FLAGS) $(DEFINES) \
1093 --input-format=rc --output-format=coff -i vim.rc -o $@
1094
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001095$(OUTDIR)/vimrcd.o: vim.rc version.h gui_w32_rc.h \
1096 tools.bmp tearoff.bmp vim.ico vim_error.ico \
1097 vim_alert.ico vim_info.ico vim_quest.ico
1098 $(WINDRES) $(WINDRES_FLAGS) $(DEFINES) -DRCDLL -DVIMDLLBASE=\\\"$(VIMDLLBASE)\\\" \
1099 --input-format=rc --output-format=coff -i vim.rc -o $@
1100else
1101$(OUTDIR)/vimrc.o: vim.rc gvim.exe.mnf version.h gui_w32_rc.h \
1102 tools.bmp tearoff.bmp vim.ico vim_error.ico \
1103 vim_alert.ico vim_info.ico vim_quest.ico
1104 $(WINDRES) $(WINDRES_FLAGS) $(DEFINES) \
1105 --input-format=rc --output-format=coff -i vim.rc -o $@
1106endif
1107
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001108$(OUTDIR):
1109 $(MKDIR) $(OUTDIR)
1110
Bram Moolenaard22a6f82019-05-24 17:17:54 +02001111$(OUTDIR)/gui_dwrite.o: gui_dwrite.cpp gui_dwrite.h
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001112 $(CC) -c $(CFLAGS) $(CXXFLAGS) gui_dwrite.cpp -o $@
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001113
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001114$(OUTDIR)/gui.o: gui.c $(INCL) $(GUI_INCL)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001115 $(CC) -c $(CFLAGS) gui.c -o $@
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001116
Bram Moolenaarc3719bd2017-11-18 22:13:31 +01001117$(OUTDIR)/beval.o: beval.c $(INCL) $(GUI_INCL)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001118 $(CC) -c $(CFLAGS) beval.c -o $@
Bram Moolenaarc3719bd2017-11-18 22:13:31 +01001119
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001120$(OUTDIR)/gui_beval.o: gui_beval.c $(INCL) $(GUI_INCL)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001121 $(CC) -c $(CFLAGS) gui_beval.c -o $@
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001122
1123$(OUTDIR)/gui_w32.o: gui_w32.c $(INCL) $(GUI_INCL)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001124 $(CC) -c $(CFLAGS) gui_w32.c -o $@
Bram Moolenaarf80451e2017-07-25 21:49:35 +02001125
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001126$(OUTDIR)/if_cscope.o: if_cscope.c $(INCL) if_cscope.h
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001127 $(CC) -c $(CFLAGS) if_cscope.c -o $@
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001128
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001129$(OUTDIR)/if_mzsch.o: if_mzsch.c $(INCL) $(MZSCHEME_INCL) $(MZ_EXTRA_DEP)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001130 $(CC) -c $(CFLAGS) if_mzsch.c -o $@
Bram Moolenaarf80451e2017-07-25 21:49:35 +02001131
1132mzscheme_base.c:
1133 $(MZSCHEME)/mzc --c-mods mzscheme_base.c ++lib scheme/base
1134
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001135# Remove -D__IID_DEFINED__ for newer versions of the w32api
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001136$(OUTDIR)/if_ole.o: if_ole.cpp $(INCL) if_ole.h
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001137 $(CC) -c $(CFLAGS) $(CXXFLAGS) if_ole.cpp -o $@
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001138
Bram Moolenaara16bc542018-10-14 16:25:10 +02001139auto/if_perl.c: if_perl.xs typemap
Bram Moolenaarf80451e2017-07-25 21:49:35 +02001140 $(XSUBPP) -prototypes -typemap \
1141 $(PERLTYPEMAP) if_perl.xs -output $@
1142
Bram Moolenaara16bc542018-10-14 16:25:10 +02001143$(OUTDIR)/if_perl.o: auto/if_perl.c $(INCL)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001144 $(CC) -c $(CFLAGS) auto/if_perl.c -o $@
Bram Moolenaara16bc542018-10-14 16:25:10 +02001145
1146
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001147$(OUTDIR)/if_ruby.o: if_ruby.c $(INCL)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001148ifeq (16, $(RUBY))
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001149 $(CC) $(CFLAGS) -U_WIN32 -c -o $@ if_ruby.c
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001150endif
1151
Bram Moolenaar97ff9b92016-06-26 20:37:46 +02001152$(OUTDIR)/iscygpty.o: iscygpty.c $(CUI_INCL)
Bram Moolenaar2bc127f2016-07-10 13:57:40 +02001153 $(CC) -c $(CFLAGS) iscygpty.c -o $(OUTDIR)/iscygpty.o -U_WIN32_WINNT -D_WIN32_WINNT=0x0600 -DUSE_DYNFILEID -DENABLE_STUB_IMPL
Bram Moolenaar97ff9b92016-06-26 20:37:46 +02001154
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001155$(OUTDIR)/main.o: main.c $(INCL) $(CUI_INCL)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001156 $(CC) -c $(CFLAGS) main.c -o $@
Bram Moolenaar97ff9b92016-06-26 20:37:46 +02001157
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001158$(OUTDIR)/netbeans.o: netbeans.c $(INCL) $(NBDEBUG_INCL) $(NBDEBUG_SRC)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001159 $(CC) -c $(CFLAGS) netbeans.c -o $@
1160
1161$(OUTDIR)/os_w32exec.o: os_w32exe.c $(INCL)
1162 $(CC) -c $(CFLAGS) -UFEAT_GUI_MSWIN os_w32exe.c -o $@
1163
1164$(OUTDIR)/os_w32exeg.o: os_w32exe.c $(INCL)
1165 $(CC) -c $(CFLAGS) os_w32exe.c -o $@
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001166
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001167$(OUTDIR)/os_win32.o: os_win32.c $(INCL) $(MZSCHEME_INCL)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001168 $(CC) -c $(CFLAGS) os_win32.c -o $@
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001169
1170$(OUTDIR)/regexp.o: regexp.c regexp_nfa.c $(INCL)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001171 $(CC) -c $(CFLAGS) regexp.c -o $@
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001172
Bram Moolenaarf80451e2017-07-25 21:49:35 +02001173$(OUTDIR)/terminal.o: terminal.c $(INCL) $(TERM_DEPS)
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001174 $(CC) -c $(CFLAGS) terminal.c -o $@
Bram Moolenaar98aefe72018-12-13 22:20:09 +01001175
Bram Moolenaardfc14552019-06-21 17:36:10 +02001176$(OUTDIR)/pathdef.o: $(PATHDEF_SRC) $(INCL)
1177 $(CC) -c $(CFLAGS) $(PATHDEF_SRC) -o $@
1178
Bram Moolenaarf80451e2017-07-25 21:49:35 +02001179
Bram Moolenaar6d0826d2017-08-22 22:12:17 +02001180CCCTERM = $(CC) -c $(CFLAGS) -Ilibvterm/include -DINLINE="" \
1181 -DVSNPRINTF=vim_vsnprintf \
1182 -DIS_COMBINING_FUNCTION=utf_iscomposing_uint \
1183 -DWCWIDTH_FUNCTION=utf_uint2cells
1184
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001185$(OUTDIR)/%.o : libvterm/src/%.c $(TERM_DEPS)
1186 $(CCCTERM) $< -o $@
Bram Moolenaarf80451e2017-07-25 21:49:35 +02001187
Bram Moolenaarf80451e2017-07-25 21:49:35 +02001188
Bram Moolenaarafde13b2019-04-28 19:46:49 +02001189$(OUTDIR)/%.o : xdiff/%.c $(XDIFF_DEPS)
1190 $(CC) -c $(CFLAGS) $< -o $@
Bram Moolenaarf80451e2017-07-25 21:49:35 +02001191
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001192
Bram Moolenaardfc14552019-06-21 17:36:10 +02001193$(PATHDEF_SRC): Make_cyg_ming.mak Make_cyg.mak Make_ming.mak
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001194ifneq (sh.exe, $(SHELL))
Bram Moolenaardfc14552019-06-21 17:36:10 +02001195 @echo creating $(PATHDEF_SRC)
1196 @echo '/* pathdef.c */' > $(PATHDEF_SRC)
1197 @echo '#include "vim.h"' >> $(PATHDEF_SRC)
1198 @echo 'char_u *default_vim_dir = (char_u *)"$(VIMRCLOC)";' >> $(PATHDEF_SRC)
1199 @echo 'char_u *default_vimruntime_dir = (char_u *)"$(VIMRUNTIMEDIR)";' >> $(PATHDEF_SRC)
1200 @echo 'char_u *all_cflags = (char_u *)"$(CC) $(CFLAGS)";' >> $(PATHDEF_SRC)
1201 @echo 'char_u *all_lflags = (char_u *)"$(LINK) $(CFLAGS) $(LFLAGS) -o $(TARGET) $(LIB) -lole32 -luuid $(LUA_LIB) $(MZSCHEME_LIBDIR) $(MZSCHEME_LIB) $(PYTHONLIB) $(PYTHON3LIB) $(RUBYLIB)";' >> $(PATHDEF_SRC)
1202 @echo 'char_u *compiled_user = (char_u *)"$(USERNAME)";' >> $(PATHDEF_SRC)
1203 @echo 'char_u *compiled_sys = (char_u *)"$(USERDOMAIN)";' >> $(PATHDEF_SRC)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001204else
Bram Moolenaardfc14552019-06-21 17:36:10 +02001205 @echo creating $(PATHDEF_SRC)
1206 @echo /* pathdef.c */ > $(PATHDEF_SRC)
1207 @echo #include "vim.h" >> $(PATHDEF_SRC)
1208 @echo char_u *default_vim_dir = (char_u *)"$(VIMRCLOC)"; >> $(PATHDEF_SRC)
1209 @echo char_u *default_vimruntime_dir = (char_u *)"$(VIMRUNTIMEDIR)"; >> $(PATHDEF_SRC)
1210 @echo char_u *all_cflags = (char_u *)"$(CC) $(CFLAGS)"; >> $(PATHDEF_SRC)
1211 @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_SRC)
1212 @echo char_u *compiled_user = (char_u *)"$(USERNAME)"; >> $(PATHDEF_SRC)
1213 @echo char_u *compiled_sys = (char_u *)"$(USERDOMAIN)"; >> $(PATHDEF_SRC)
Bram Moolenaar4f7e8212014-11-05 13:53:32 +01001214endif
Bram Moolenaar96e7a6e2017-09-23 19:48:29 +02001215
1216# vim: set noet sw=8 ts=8 sts=0 wm=0 tw=0: