xref: /vim-8.2.3635/src/Makefile (revision 8cc2a9c0)
1# Makefile for Vim on Unix and Unix-like systems	vim:ts=8:sw=8:tw=78
2#
3# This Makefile is loosely based on the GNU Makefile conventions found in
4# standards.info.
5#
6# Compiling Vim, summary:
7#
8#	3. make
9#	5. make install
10#
11# Compiling Vim, details:
12#
13# Edit this file for adjusting to your system. You should not need to edit any
14# other file for machine specific things!
15# The name of this file MUST be Makefile (note the uppercase 'M').
16#
17# 1. Edit this Makefile  {{{1
18#	The defaults for Vim should work on most machines, but you may want to
19#	uncomment some lines or make other changes below to tune it to your
20#	system, compiler or preferences.  Uncommenting means that the '#' in
21#	the first column of a line is removed.
22#	- If you want a version of Vim that is small and starts up quickly,
23#	  you might want to disable the GUI, X11, Perl, Python and Tcl.
24#	- Uncomment the line with --disable-gui if you have Motif, GTK and/or
25#	  Athena but don't want to make gvim (the GUI version of Vim with nice
26#	  menus and scrollbars, but makes Vim bigger and startup slower).
27#	- Uncomment --disable-darwin if on Mac OS X but you want to compile a
28#	  Unix version.
29#	- Uncomment the line "CONF_OPT_X = --without-x" if you have X11 but
30#	  want to disable using X11 libraries.	This speeds up starting Vim,
31#	  but the window title will not be set and the X11 selection can not
32#	  be used.
33#	- Uncomment the line "CONF_OPT_XSMP = --disable-xsmp" if you have the
34#	  X11 Session Management Protocol (XSMP) library (libSM) but do not
35#	  want to use it.
36#	  This can speedup Vim startup but Vim loses the ability to catch the
37#	  user logging out from session-managers like GNOME and work
38#	  could be lost.
39#	- Uncomment one or more of these lines to include an interface;
40#	  each makes Vim quite a bit bigger:
41#		--enable-luainterp	for Lua interpreter
42#		--enable-mzschemeinterp	for MzScheme interpreter
43#		--enable-perlinterp	for Perl interpreter
44#		--enable-python3interp	for Python3 interpreter
45#		--enable-pythoninterp	for Python interpreter
46#		--enable-rubyinterp	for Ruby interpreter
47#		--enable-tclinterp	for Tcl interpreter
48#		--enable-cscope		for Cscope interface
49#	- Uncomment one of the lines with --with-features= to enable a set of
50#	  features (but not the interfaces just mentioned).
51#	- Uncomment the line with --disable-acl to disable ACL support even
52#	  though your system supports it.
53#	- Uncomment the line with --disable-gpm to disable gpm support
54#	  even though you have gpm libraries and includes.
55#	- Uncomment the line with --disable-sysmouse to disable sysmouse
56#	  support even though you have /dev/sysmouse and includes.
57#	- Uncomment one of the lines with CFLAGS and/or CC if you have
58#	  something very special or want to tune the optimizer.
59#	- Search for the name of your system to see if it needs anything
60#	  special.
61#	- A few versions of make use '.include "file"' instead of 'include
62#	  file'.  Adjust the include line below if yours does.
63#
64# 2. Edit feature.h  {{{1
65#	Only if you do not agree with the default compile features, e.g.:
66#	- you want Vim to be as vi compatible as it can be
67#	- you want to use Emacs tags files
68#	- you want right-to-left editing (Hebrew)
69#	- you want 'langmap' support (Greek)
70#	- you want to remove features to make Vim smaller
71#
72# 3. "make"  {{{1
73#	Will first run ./configure with the options in this file. Then it will
74#	start make again on this Makefile to do the compiling. You can also do
75#	this in two steps with:
76#		make config
77#		make
78#	The configuration phase creates/overwrites auto/config.h and
79#	auto/config.mk.
80#	The configure script is created with "make autoconf".  It can detect
81#	different features of your system and act accordingly.  However, it is
82#	not correct for all systems.  Check this:
83#	- If you have X windows, but configure could not find it or reported
84#	  another include/library directory then you wanted to use, you have
85#	  to set CONF_OPT_X below.  You might also check the installation of
86#	  xmkmf.
87#	- If you have --enable-gui=motif and have Motif on your system, but
88#	  configure reports "checking for location of gui... <not found>", you
89#	  have to set GUI_INC_LOC and GUI_LIB_LOC below.
90#	If you changed something, do this to run configure again:
91#		make reconfig
92#
93#	- If you do not trust the automatic configuration code, then inspect
94#	  auto/config.h and auto/config.mk, before starting the actual build
95#	  phase. If possible edit this Makefile, rather than auto/config.mk --
96#	  especially look at the definition of VIMLOC below. Note that the
97#	  configure phase overwrites auto/config.mk and auto/config.h again.
98#	- If you get error messages, find out what is wrong and try to correct
99#	  it in this Makefile. You may need to do "make reconfig" when you
100#	  change anything that configure uses (e.g. switching from an old C
101#	  compiler to an ANSI C compiler). Only when auto/configure does
102#	  something wrong you may need to change one of the other files. If
103#	  you find a clean way to fix the problem, consider sending a note to
104#	  the author of autoconf ([email protected]) or Vim
105#	  ([email protected]). Don't bother to do that when you made a hack
106#	  solution for a non-standard system.
107#
108# 4. "make test"  {{{1
109#	This is optional.  This will run Vim scripts on a number of test
110#	files, and compare the produced output with the expected output.
111#	If all is well, you will get the "ALL DONE" message in the end.  If a
112#	test fails you get "TEST FAILURE".  See below (search for "/^test").
113#
114# 5. "make install"  {{{1
115#	If the new Vim seems to be working OK you can install it and the
116#	documentation in the appropriate location. The default is
117#	"/usr/local".  Change "prefix" below to change the location.
118#	"auto/pathdef.c" will be compiled again after changing this to make
119#	the executable know where the help files are located.
120#	Note that any existing executable is removed or overwritten.  If you
121#	want to keep it you will have to make a backup copy first.
122#	The runtime files are in a different directory for each version.  You
123#	might want to delete an older version.
124#	If you don't want to install everything, there are other targets:
125#		make installvim		only installs Vim, not the tools
126#		make installvimbin	only installs the Vim executable
127#		make installruntime	installs most of the runtime files
128#		make installrtbase	only installs the Vim help and
129#							runtime files
130#		make installlinks	only installs the Vim binary links
131#		make installmanlinks	only installs the Vim manpage links
132#		make installmacros	only installs the Vim macros
133#		make installpack	only installs the packages
134#		make installtutorbin	only installs the Vim tutor program
135#		make installtutor	only installs the Vim tutor files
136#		make installspell	only installs the spell files
137#		make installtools	only installs xxd
138#	If you install Vim, not to install for real but to prepare a package
139#	or RPM, set DESTDIR to the root of the tree.
140#
141# 6. Use Vim until a new version comes out.  {{{1
142#
143# 7. "make uninstall_runtime"  {{{1
144#	Will remove the runtime files for the current version.	This is safe
145#	to use while another version is being used, only version-specific
146#	files will be deleted.
147#	To remove the runtime files of another version:
148#		make uninstall_runtime VIMRTDIR=/vim54
149#	If you want to delete all installed files, use:
150#		make uninstall
151#	Note that this will delete files that have the same name for any
152#	version, thus you might need to do a "make install" soon after this.
153#	Be careful not to remove a version of Vim that is still being used!
154#	To find out which files and directories will be deleted, use:
155#		make -n uninstall
156# }}}
157#
158### This Makefile has been successfully tested on many systems. {{{
159### Only the ones that require special options are mentioned here.
160### Check the (*) column for remarks, listed below.
161### Later code changes may cause small problems, otherwise Vim is supposed to
162### compile and run without problems.
163
164#system:	      configurations:		     version (*) tested by:
165#-------------	      ------------------------	     -------  -  ----------
166#AIX 3.2.5	      cc (not gcc)   -			4.5  (M) Will Fiveash
167#AIX 4		      cc	     +X11 -GUI		3.27 (4) Axel Kielhorn
168#AIX 4.1.4	      cc	     +X11 +GUI		4.5  (5) Nico Bakker
169#AIX 4.2.1	      cc				5.2k (C) Will Fiveash
170#AIX 4.3.3.12	      xic 3.6.6				5.6  (5) David R. Favor
171#A/UX 3.1.1	      gcc	     +X11		4.0  (6) Jim Jagielski
172#BeOS PR	      mwcc DR3				5.0n (T) Olaf Seibert
173#BSDI 2.1 (x86)       shlicc2 gcc-2.6.3 -X11 X11R6	4.5  (1) Jos Backus
174#BSD/OS 3.0 (x86)     gcc gcc-2.7.2.1 -X11 X11R6	4.6c (1) Jos Backus
175#CX/UX 6.2	      cc	     +X11 +GUI_Mofif	5.4  (V) Kipp E. Howard
176#DG/UX 5.4*	      gcc 2.5.8      GUI		5.0e (H) Jonas Schlein
177#DG/UX 5.4R4.20       gcc 2.7.2      GUI		5.0s (H) Rocky Olive
178#HP-UX (most)	      c89 cc				5.1  (2) Bram Moolenaar
179#HP-UX_9.04	      cc	     +X11 +Motif	5.0  (2) Carton Lao
180#Irix 6.3 (O2)	      cc	     ?			4.5  (L) Edouard Poor
181#Irix 6.4	      cc	     ?			5.0m (S) Rick Sayre
182#Irix 6.5	      cc	     ?			6.0  (S) David Harrison
183#Irix 64 bit						4.5  (K) Jon Wright
184#Linux 2.0	      gcc-2.7.2      Infomagic Motif	4.3  (3) Ronald Rietman
185#Linux 2.0.31	      gcc	     +X11 +GUI Athena	5.0w (U) Darren Hiebert
186#LynxOS 3.0.1	      2.9-gnupro-98r2 +X11 +GUI Athena  5.7.1(O) Lorenz Hahn
187#LynxOS 3.1.0	      2.9-gnupro-98r2 +X11 +GUI Athena  5.7.1(O) Lorenz Hahn
188#NEC UP4800 UNIX_SV 4.2MP  cc	     +X11R6 Motif,Athena4.6b (Q) Lennart Schultz
189#NetBSD 1.0A	      gcc-2.4.5      -X11 -GUI		3.21 (X) Juergen Weigert
190#QNX 4.2	      wcc386-10.6    -X11		4.2  (D) G.F. Desrochers
191#QNX 4.23	      Watcom	     -X11		4.2  (F) John Oleynick
192#SCO Unix v3.2.5      cc	     +X11 Motif		3.27 (C) M. Kuperblum
193#SCO Open Server 5    gcc 2.7.2.3    +X11 +GUI Motif	5.3  (A) Glauber Ribeiro
194#SINIX-N 5.43 RM400 R4000   cc	     +X11 +GUI		5.0l (I) Martin Furter
195#SINIX-Z 5.42 i386    gcc 2.7.2.3    +X11 +GUI Motif	5.1  (I) Joachim Fehn
196#SINIX-Y 5.43 RM600 R4000  gcc 2.7.2.3 +X11 +GUI Motif	5.1  (I) Joachim Fehn
197#Reliant/SINIX 5.44   cc	     +X11 +GUI		5.5a (I) B. Pruemmer
198#SNI Targon31 TOS 4.1.11 gcc-2.4.5   +X11 -GUI		4.6c (B) Paul Slootman
199#Solaris 2.4 (Sparc)  cc	     +X11 +GUI		3.29 (9) Glauber
200#Solaris 2.4/2.5      clcc	     +X11 -GUI openwin	3.20 (7) Robert Colon
201#Solaris 2.5 (sun4m)  cc (SC4.0)     +X11R6 +GUI (CDE)	4.6b (E) Andrew Large
202#Solaris 2.5	      cc	     +X11 +GUI Athena	4.2  (9) Sonia Heimann
203#Solaris 2.5	      gcc 2.5.6      +X11 Motif		5.0m (R) Ant. Colombo
204#Solaris 2.6	      gcc 2.8.1      ncurses		5.3  (G) Larry W. Virden
205#Solaris with -lthread					5.5  (W) K. Nagano
206#Solaris	      gcc				     (b) Riccardo
207#SunOS 4.1.x			     +X11 -GUI		5.1b (J) Bram Moolenaar
208#SunOS 4.1.3_U1 (sun4c) gcc	     +X11 +GUI Athena	5.0w (J) Darren Hiebert
209#SUPER-UX 6.2 (NEC SX-4) cc	     +X11R6 Motif,Athena4.6b (P) Lennart Schultz
210#Tandem/NSK                                                  (c) Matthew Woehlke
211#Unisys 6035	      cc	     +X11 Motif		5.3  (8) Glauber Ribeiro
212#ESIX V4.2	      cc	     +X11		6.0  (a) Reinhard Wobst
213#Mac OS X 10.[23]     gcc	     Carbon		6.2  (x) Bram Moolenaar
214# }}}
215
216# (*)  Remarks: {{{
217#
218# (1)  Uncomment line below for shlicc2
219# (2)  HPUX with compile problems or wrong digraphs, uncomment line below
220# (3)  Infomagic Motif needs GUI_LIB_LOC and GUI_INC_LOC set, see below.
221#      And add "-lXpm" to MOTIF_LIBS2.
222# (4)  For cc the optimizer must be disabled (use CFLAGS= after running
223#      configure) (symptom: ":set termcap" output looks weird).
224# (5)  Compiler may need extra argument, see below.
225# (6)  See below for a few lines to uncomment
226# (7)  See below for lines which enable the use of clcc
227# (8)  Needs some EXTRA_LIBS, search for Unisys below
228# (9)  Needs an extra compiler flag to compile gui_at_sb.c, see below.
229# (A)  May need EXTRA_LIBS, see below
230# (B)  Can't compile GUI because there is no waitpid()...  Disable GUI below.
231# (C)  Force the use of curses instead of termcap, see below.
232# (D)  Uncomment lines below for QNX
233# (E)  You might want to use termlib instead of termcap, see below.
234# (F)  See below for instructions.
235# (G)  Using ncurses version 4.2 has reported to cause a crash.  Use the
236#      Sun curses library instead.
237# (H)  See line for EXTRA_LIBS below.
238# (I)  SINIX-N 5.42 and 5.43 need some EXTRA_LIBS.  Also for Reliant-Unix.
239# (J)  If you get undefined symbols, see below for a solution.
240# (K)  See lines to uncomment below for machines with 64 bit pointers.
241# (L)  For Silicon Graphics O2 workstations remove "-lnsl" from auto/config.mk
242# (M)  gcc version cygnus-2.0.1 does NOT work (symptom: "dl" deletes two
243#      characters instead of one).
244# (N)  SCO with decmouse.
245# (O)  LynxOS needs EXTRA_LIBS, see below.
246# (P)  For SuperUX 6.2 on NEC SX-4 see a few lines below to uncomment.
247# (Q)  For UNIXSVR 4.2MP on NEC UP4800 see below for lines to uncomment.
248# (R)  For Solaris 2.5 (or 2.5.1) with gcc > 2.5.6, uncomment line below.
249# (S)  For Irix 6.x with MipsPro compiler, use -OPT:Olimit.  See line below.
250# (T)  See ../doc/os_beos.txt.
251# (U)  Must uncomment CONF_OPT_PYTHON option below to disable Python
252#      detection, since the configure script runs into an error when it
253#      detects Python (probably because of the bash shell).
254# (V)  See lines to uncomment below.
255# (X)  Need to use the .include "auto/config.mk" line below
256# (Y)  See line with c89 below
257# (Z)  See lines with cc or c89 below
258# (a)  See line with EXTRA_LIBS below.
259# (b)  When using gcc with the Solaris linker, make sure you don't use GNU
260#      strip, otherwise the binary may not run: "Cannot find ELF".
261# (c)  Add -lfloss to EXTRA_LIBS, see below.
262# (x)  When you get warnings for precompiled header files, run
263#      "sudo fixPrecomps".  Also see CONF_OPT_DARWIN below.
264# }}}
265
266
267#DO NOT CHANGE the next line, we need it for configure to find the compiler
268#instead of using the default from the "make" program.
269#Use a line further down to change the value for CC.
270CC=
271
272# Change and use these defines if configure cannot find your Motif stuff.
273# Unfortunately there is no "standard" location for Motif. {{{
274# These defines can contain a single directory (recommended) or a list of
275# directories (for when you are working with several systems). The LAST
276# directory that exists is used.
277# When changed, run "make reconfig" next!
278#GUI_INC_LOC = -I/usr/include/Motif2.0 -I/usr/include/Motif1.2
279#GUI_LIB_LOC = -L/usr/lib/Motif2.0 -L/usr/lib/Motif1.2
280### Use these two lines for Infomagic Motif (3)
281#GUI_INC_LOC = -I/usr/X11R6/include
282#GUI_LIB_LOC = -L/usr/X11R6/lib
283# }}}
284
285# Defaults used when auto/config.mk does not exist.
286srcdir = .
287VIMNAME = vim
288EXNAME = ex
289VIEWNAME = view
290
291######################## auto/config.mk ######################## {{{1
292# At this position auto/config.mk is included. When starting from the
293# toplevel Makefile it is almost empty. After running auto/configure it
294# contains settings that have been discovered for your system. Settings below
295# this include override settings in auto/config.mk!
296
297# Note: If make fails because auto/config.mk does not exist (it is not
298# included in the repository), do:
299#    cp config.mk.dist auto/config.mk
300
301# (X) How to include auto/config.mk depends on the version of "make" you have,
302#     if the current choice doesn't work, try the other one.
303
304include auto/config.mk
305#.include "auto/config.mk"
306CClink = $(CC)
307
308#}}}
309
310# Include the configuration choices first, so we can override everything
311# below. As shipped, this file contains a target that causes to run
312# configure. Once configure was run, this file contains a list of
313# make variables with predefined values instead. Thus any second invocation
314# of make, will build Vim.
315
316# CONFIGURE - configure arguments {{{1
317# You can give a lot of options to configure.
318# Change this to your desire and do 'make config' afterwards
319
320# examples (can only use one!):
321#CONF_ARGS = --exec-prefix=/usr
322#CONF_ARGS = --with-vim-name=vim7 --with-ex-name=ex7 --with-view-name=view7
323#CONF_ARGS = --with-global-runtime=/etc/vim
324#CONF_ARGS = --with-local-dir=/usr/share
325#CONF_ARGS = --without-local-dir
326
327# Use this one if you distribute a modified version of Vim.
328#CONF_ARGS = --with-modified-by="John Doe"
329
330# GUI - For creating Vim with GUI (gvim) (B)
331# Uncomment this line when you don't want to get the GUI version, although you
332# have GTK, Motif and/or Athena.  Also use --without-x if you don't want X11
333# at all.
334#CONF_OPT_GUI = --disable-gui
335
336# Uncomment one of these lines if you have that GUI but don't want to use it.
337# The automatic check will use another one that can be found.
338# Gnome is disabled by default, because it may cause trouble.
339#
340# When both GTK+ 2 and GTK+ 3 are possible then GTK+ 2 will be selected.
341# To use GTK+ 3 instead use --enable-gui=gtk3 (see below).
342#CONF_OPT_GUI = --disable-gtk2-check
343#CONF_OPT_GUI = --enable-gnome2-check
344#CONF_OPT_GUI = --disable-gtk3-check
345#CONF_OPT_GUI = --disable-motif-check
346#CONF_OPT_GUI = --disable-athena-check
347#CONF_OPT_GUI = --disable-nextaw-check
348
349# Uncomment one of these lines to select a specific GUI to use.
350# When using "yes" or nothing, configure will use the first one found: GTK+,
351# Motif or Athena.
352#
353# GTK versions that are known not to work 100% are rejected.
354# Use "--disable-gtktest" to accept them anyway.
355# For GTK 1 use Vim 7.2.
356#
357# GNOME means GTK with Gnome support.  If using GTK and --enable-gnome-check
358# is used then GNOME will automatically be used if it is found.  If you have
359# GNOME, but do not want to use it (e.g., want a GTK-only version), then use
360# --enable-gui=gtk or leave out --enable-gnome-check.
361#
362# GNOME makes sense only for GTK+ 2.  Avoid use of --enable-gnome-check with
363# GTK+ 3 build, as the functionality of GNOME is already incooperated into
364# GTK+ 3.
365#
366# If the selected GUI isn't found, the GUI is disabled automatically
367#CONF_OPT_GUI = --enable-gui=gtk2
368#CONF_OPT_GUI = --enable-gui=gtk2 --disable-gtktest
369#CONF_OPT_GUI = --enable-gui=gnome2
370#CONF_OPT_GUI = --enable-gui=gnome2 --disable-gtktest
371#CONF_OPT_GUI = --enable-gui=gtk3
372#CONF_OPT_GUI = --enable-gui=gtk3 --disable-gtktest
373#CONF_OPT_GUI = --enable-gui=motif
374#CONF_OPT_GUI = --enable-gui=motif --with-motif-lib="-static -lXm -shared"
375#CONF_OPT_GUI = --enable-gui=athena
376#CONF_OPT_GUI = --enable-gui=nextaw
377
378# Carbon GUI for Mac OS X
379#CONF_OPT_GUI = --enable-gui=carbon
380
381# Uncomment this line to run an individual test with gvim.
382#GUI_TESTARG = GUI_FLAG=-g
383
384# DARWIN - detecting Mac OS X
385# Uncomment this line when you want to compile a Unix version of Vim on
386# Darwin.  None of the Mac specific options or files will be used.
387#CONF_OPT_DARWIN = --disable-darwin
388
389# Select the architecture supported.  Default is to build for the current
390# platform.  Use "both" for a universal binary.  That probably doesn't work
391# when including Perl, Python, etc.
392#CONF_OPT_DARWIN = --with-mac-arch=i386
393#CONF_OPT_DARWIN = --with-mac-arch=ppc
394#CONF_OPT_DARWIN = --with-mac-arch=both
395
396# Uncomment the next line to fail if one of the requested language interfaces
397# cannot be configured.  Without this Vim will be build anyway, without
398# the failing interfaces.
399#CONF_OPT_FAIL = --enable-fail-if-missing
400
401# LUA
402# Uncomment one of these when you want to include the Lua interface.
403# First one is for static linking, second one for dynamic loading.
404# Use --with-luajit if you want to use LuaJIT instead of Lua.
405# Set PATH environment variable to find lua or luajit executable.
406#CONF_OPT_LUA = --enable-luainterp
407#CONF_OPT_LUA = --enable-luainterp=dynamic
408#CONF_OPT_LUA = --enable-luainterp --with-luajit
409#CONF_OPT_LUA = --enable-luainterp=dynamic --with-luajit
410# Lua installation dir (when not set uses $LUA_PREFIX or defaults to /usr)
411#CONF_OPT_LUA_PREFIX = --with-lua-prefix=/usr/local
412
413# MZSCHEME
414# Uncomment this when you want to include the MzScheme interface.
415# NOTE: does not work well together with valgrind.
416#CONF_OPT_MZSCHEME = --enable-mzschemeinterp
417# PLT/mrscheme/drscheme Home dir; the PLTHOME environment variable also works
418#CONF_OPT_PLTHOME  = --with-plthome=/usr/local/plt
419#CONF_OPT_PLTHOME  = --with-plthome=/usr/local/drscheme
420#CONF_OPT_PLTHOME  = --with-plthome=/home/me/mz
421
422# PERL
423# Uncomment one of these when you want to include the Perl interface.
424# First one is for static linking, second one for dynamic loading.
425# The Perl option sometimes causes problems, because it adds extra flags
426#
427# to the command line.	If you see strange flags during compilation, check in
428# auto/config.mk where they come from.  If it's PERL_CFLAGS, try commenting
429# the next line.
430# When you get an error for a missing "perl.exp" file, try creating an empty
431# one: "touch perl.exp".
432# This requires at least "small" features, "tiny" doesn't work.
433#CONF_OPT_PERL = --enable-perlinterp
434#CONF_OPT_PERL = --enable-perlinterp=dynamic
435
436# PYTHON
437# Uncomment this when you want to include the Python interface.
438# Requires small features or better, fails with tiny features.
439# NOTE: This may cause threading to be enabled, which has side effects (such
440# as using different libraries and debugging becomes more difficult).
441# NOTE: Using this together with Perl may cause a crash in initialization.
442# For Python3 support make a symbolic link in /usr/local/bin:
443#	ln -s python3 python3.1
444# If both python2.x and python3.x are enabled then the linking will be via
445# dlopen(), dlsym(), dlclose(), i.e. pythonX.Y.so must be available
446# However, this may still cause problems, such as "import termios" failing.
447# Build two separate versions of Vim in that case.
448#CONF_OPT_PYTHON = --enable-pythoninterp
449#CONF_OPT_PYTHON = --enable-pythoninterp=dynamic
450#CONF_OPT_PYTHON3 = --enable-python3interp
451#CONF_OPT_PYTHON3 = --enable-python3interp=dynamic
452
453# RUBY
454# Uncomment this when you want to include the Ruby interface.
455# First one for static linking, second one for loading when used.
456# Note: you need the development package (e.g., ruby1.9.1-dev on Ubuntu).
457#CONF_OPT_RUBY = --enable-rubyinterp
458#CONF_OPT_RUBY = --enable-rubyinterp=dynamic
459#CONF_OPT_RUBY = --enable-rubyinterp --with-ruby-command=ruby1.9.1
460
461# TCL
462# Uncomment this when you want to include the Tcl interface.
463# First one is for static linking, second one for dynamic loading.
464#CONF_OPT_TCL = --enable-tclinterp
465#CONF_OPT_TCL = --enable-tclinterp=dynamic
466#CONF_OPT_TCL = --enable-tclinterp --with-tclsh=tclsh8.4
467
468# CSCOPE
469# Uncomment this when you want to include the Cscope interface.
470#CONF_OPT_CSCOPE = --enable-cscope
471
472# WORKSHOP - Sun Visual Workshop interface.  Only works with Motif!
473#CONF_OPT_WORKSHOP = --enable-workshop
474
475# NETBEANS - NetBeans interface. Only works with Motif, GTK, and gnome.
476# Motif version must have XPM libraries (see |workshop-xpm|).
477# Uncomment this when you do not want the netbeans interface.
478#CONF_OPT_NETBEANS = --disable-netbeans
479
480# CHANNEL - inter process communication. Same conditions as NetBeans.
481# Uncomment this when you do not want inter process communication.
482#CONF_OPT_CHANNEL = --disable-channel
483
484# MULTIBYTE - To edit multi-byte characters.
485# Uncomment this when you want to edit a multibyte language.
486# It's automatically enabled with normal features, GTK or IME support.
487# Note: Compile on a machine where setlocale() actually works, otherwise the
488# configure tests may fail.
489#CONF_OPT_MULTIBYTE = --enable-multibyte
490
491# NLS - National Language Support
492# Uncomment this when you do not want to support translated messages, even
493# though configure can find support for it.
494#CONF_OPT_NLS = --disable-nls
495
496# XIM - X Input Method.  Special character input support for X11 (Chinese,
497# Japanese, special symbols, etc).  Also needed for dead-key support.
498# When omitted it's automatically enabled for the X-windows GUI.
499# HANGUL - Input Hangul (Korean) language using internal routines.
500# Uncomment one of these when you want to input a multibyte language.
501#CONF_OPT_INPUT = --enable-xim
502#CONF_OPT_INPUT = --disable-xim
503#CONF_OPT_INPUT = --enable-hangulinput
504
505# FONTSET - X fontset support for output of languages with many characters.
506# Uncomment this when you want to output a multibyte language.
507#CONF_OPT_OUTPUT = --enable-fontset
508
509# ACL - Uncomment this when you do not want to include ACL support, even
510# though your system does support it.  E.g., when it's buggy.
511#CONF_OPT_ACL = --disable-acl
512
513# gpm - For mouse support on Linux console via gpm
514# Uncomment this when you do not want to include gpm support, even
515# though you have gpm libraries and includes.
516#CONF_OPT_GPM = --disable-gpm
517
518# sysmouse - For mouse support on FreeBSD and DragonFly console via sysmouse
519# Uncomment this when you do not want do include sysmouse support, even
520# though you have /dev/sysmouse and includes.
521#CONF_OPT_SYSMOUSE = --disable-sysmouse
522
523# FEATURES - For creating Vim with more or less features
524# Uncomment one of these lines when you want to include few to many features.
525# The default is "huge" for most systems.
526#CONF_OPT_FEAT = --with-features=tiny
527#CONF_OPT_FEAT = --with-features=small
528#CONF_OPT_FEAT = --with-features=normal
529#CONF_OPT_FEAT = --with-features=big
530#CONF_OPT_FEAT = --with-features=huge
531
532# COMPILED BY - For including a specific e-mail address for ":version".
533#CONF_OPT_COMPBY = "--with-compiledby=John Doe <[email protected]>"
534
535# X WINDOWS DISABLE - For creating a plain Vim without any X11 related fancies
536# (otherwise Vim configure will try to include xterm titlebar access)
537# Also disable the GUI above, otherwise it will be included anyway.
538# When both GUI and X11 have been disabled this may save about 15% of the
539# code and make Vim startup quicker.
540#CONF_OPT_X = --without-x
541
542# X WINDOWS DIRECTORY - specify X directories
543# If configure can't find you X stuff, or if you have multiple X11 derivatives
544# installed, you may wish to specify which one to use.
545# Select nothing to let configure choose.
546# This here selects openwin (as found on sun).
547#XROOT = /usr/openwin
548#CONF_OPT_X = --x-include=$(XROOT)/include --x-libraries=$(XROOT)/lib
549
550# X11 Session Management Protocol support
551# Vim will try to use XSMP to catch the user logging out if there are unsaved
552# files.  Uncomment this line to disable that (it prevents vim trying to open
553# communications with the session manager).
554#CONF_OPT_XSMP = --disable-xsmp
555
556# You may wish to include xsmp but use exclude xsmp-interact if the logout
557# XSMP functionality does not work well with your session-manager (at time of
558# writing, this would be early GNOME-1 gnome-session: it 'freezes' other
559# applications after Vim has cancelled a logout (until Vim quits).  This
560# *might* be the Vim code, but is more likely a bug in early GNOME-1.
561# This disables the dialog that asks you if you want to save files or not.
562#CONF_OPT_XSMP = --disable-xsmp-interact
563
564# COMPILER - Name of the compiler {{{1
565# The default from configure will mostly be fine, no need to change this, just
566# an example. If a compiler is defined here, configure will use it rather than
567# probing for one. It is dangerous to change this after configure was run.
568# Make will use your choice then -- but beware: Many things may change with
569# another compiler.  It is wise to run 'make reconfig' to start all over
570# again.
571#CC = cc
572#CC = gcc
573#CC = clang
574
575# COMPILER FLAGS - change as you please. Either before running {{{1
576# configure or afterwards. For examples see below.
577# When using -g with some older versions of Linux you might get a
578# statically linked executable.
579# When not defined, configure will try to use -O2 -g for gcc and -O for cc.
580#CFLAGS = -g
581#CFLAGS = -O
582
583# Optimization limits - depends on the compiler.  Automatic check in configure
584# doesn't work very well, because many compilers only give a warning for
585# unrecognized arguments.
586#CFLAGS = -O -OPT:Olimit=2600
587#CFLAGS = -O -Olimit 2000
588#CFLAGS = -O -FOlimit,2000
589
590# Often used for GCC: mixed optimizing, lot of optimizing, debugging
591#CFLAGS = -g -O2 -fno-strength-reduce -Wall -Wshadow -Wmissing-prototypes
592#CFLAGS = -g -O2 -fno-strength-reduce -Wall -Wmissing-prototypes
593#CFLAGS = -g -Wall -Wmissing-prototypes
594#CFLAGS = -O6 -fno-strength-reduce -Wall -Wshadow -Wmissing-prototypes
595#CFLAGS = -g -DDEBUG -Wall -Wshadow -Wmissing-prototypes
596#CFLAGS = -g -O2 '-DSTARTUPTIME="vimstartup"' -fno-strength-reduce -Wall -Wmissing-prototypes
597
598# Use this with GCC to check for mistakes, unused arguments, etc.
599#CFLAGS = -g -Wall -Wextra -Wshadow -Wmissing-prototypes -Wunreachable-code -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
600#CFLAGS = -g -O2 -Wall -Wextra -Wmissing-prototypes -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1 -DU_DEBUG
601#PYTHON_CFLAGS_EXTRA = -Wno-missing-field-initializers
602#MZSCHEME_CFLAGS_EXTRA = -Wno-unreachable-code -Wno-unused-parameter
603
604# EFENCE - Electric-Fence malloc debugging: catches memory accesses beyond
605# allocated memory (and makes every malloc()/free() very slow).
606# Electric Fence is free (search ftp sites).
607# You may want to set the EF_PROTECT_BELOW environment variable to check the
608# other side of allocated memory.
609# On FreeBSD you might need to enlarge the number of mmaps allowed.  Do this
610# as root: sysctl -w vm.max_proc_mmap=30000
611#EXTRA_LIBS = /usr/local/lib/libefence.a
612
613# Autoconf binary.
614AUTOCONF = autoconf
615
616# PURIFY - remove the # to use the "purify" program (hoi Nia++!)
617#PURIFY = purify
618
619# VALGRIND - remove the # to use valgrind for memory leaks and access errors.
620#            Used for the unittest targets.
621# VALGRIND = valgrind --tool=memcheck --leak-check=yes --num-callers=25 --log-file=valgrind.$@
622
623# NBDEBUG - debugging the netbeans interface.
624#EXTRA_DEFS = -DNBDEBUG
625
626# }}}
627
628# LINT - for running lint
629#  For standard Unix lint
630LINT = lint
631LINT_OPTIONS = -beprxzF
632#  For splint
633#  It doesn't work well, crashes on include files and non-ascii characters.
634#LINT = splint
635#LINT_OPTIONS = +unixlib -weak -macrovarprefixexclude -showfunc -linelen 9999
636
637# PROFILING - Uncomment the next two lines to do profiling with gcc and gprof.
638# Might not work with GUI or Perl.
639# For unknown reasons adding "-lc" fixes a linking problem with some versions
640# of GCC.  That's probably a bug in the "-pg" implementation.
641# After running Vim see the profile result with: gprof vim gmon.out | vim -
642# Need to recompile everything after changing this: "make clean" "make".
643#PROFILE_CFLAGS = -pg -g -DWE_ARE_PROFILING
644#PROFILE_LIBS = -pg
645#PROFILE_LIBS = -pg -lc
646
647
648# TEST COVERAGE - Uncomment the two lines below the explanation to get code
649# coverage information. (provided by Yegappan Lakshmanan)
650# 1. make clean, run configure and build Vim as usual.
651# 2. Generate the baseline code coverage information:
652#        $ lcov -c -i -b . -d objects -o objects/coverage_base.info
653# 3. Run "make test" to run the unit tests.  The code coverage information will
654#    be generated in the src/objects directory.
655# 4. Generate the code coverage information from the tests:
656#        $ lcov -c -b . -d objects/ -o objects/coverage_test.info
657# 5. Combine the baseline and test code coverage data:
658#        $ lcov -a objects/coverage_base.info -a objects/coverage_test.info -o objects/coverage_total.info
659# 6. Process the test coverage data and generate a report in html:
660#        $ genhtml objects/coverage_total.info -o objects
661# 7. Open the objects/index.html file in a web browser to view the coverage
662#    information.
663#
664# PROFILE_CFLAGS=-g -O0 -fprofile-arcs -ftest-coverage
665# LDFLAGS=--coverage
666
667
668# Uncomment one of the next two lines to compile Vim with the
669# address sanitizer or with the undefined sanitizer.  Works with gcc and
670# clang.  May make Vim twice as slow.  Errors reported on stderr.
671# More at: https://code.google.com/p/address-sanitizer/
672#SANITIZER_CFLAGS = -g -O0 -fsanitize=address -fno-omit-frame-pointer
673#SANITIZER_CFLAGS = -g -O0 -fsanitize=undefined -fno-omit-frame-pointer
674SANITIZER_LIBS = $(SANITIZER_CFLAGS)
675
676# MEMORY LEAK DETECTION
677# Requires installing the ccmalloc library.
678# Configuration is in the .ccmalloc or ~/.ccmalloc file.
679# Doesn't work very well, since memory linked to from global variables
680# (in libraries) is also marked as leaked memory.
681#LEAK_CFLAGS = -DEXITFREE
682#LEAK_LIBS = -lccmalloc
683
684# Uncomment this line to have Vim call abort() when an internal error is
685# detected.  Useful when using a tool to find errors.
686#ABORT_CLFAGS = -DABORT_ON_INTERNAL_ERROR
687
688#####################################################
689###  Specific systems, check if yours is listed!  ### {{{
690#####################################################
691
692### Uncomment things here only if the values chosen by configure are wrong.
693### It's better to adjust configure.ac and "make autoconf", if you can!
694### Then send the required changes to configure.ac to the bugs list.
695
696### (1) BSD/OS 2.0.1, 2.1 or 3.0 using shared libraries
697###
698#CC = shlicc2
699#CFLAGS = -O2 -g -m486 -Wall -Wshadow -Wmissing-prototypes -fno-builtin
700
701### (2) HP-UX with a non-ANSI cc, use the c89 ANSI compiler
702###	The first probably works on all systems
703###	The second should work a bit better on newer systems
704###	The third should work a bit better on HPUX 11.11
705###	Information provided by: Richard Allen <[email protected]>
706#CC = c89 -D_HPUX_SOURCE
707#CC = c89 -O +Onolimit +ESlit -D_HPUX_SOURCE
708#CC = c89 -O +Onolimit +ESlit +e -D_HPUX_SOURCE
709
710### (2) For HP-UX: Enable the use of a different set of digraphs.  Use this
711###	when the default (ISO) digraphs look completely wrong.
712###	After changing this do "touch digraph.c; make".
713#EXTRA_DEFS = -DHPUX_DIGRAPHS
714
715### (2) For HP-UX: 9.04 cpp default macro definition table of 128000 bytes
716###	is too small to compile many routines.	It produces too much defining
717###	and no space errors.
718###	Uncomment the following to specify a larger macro definition table.
719#CFLAGS = -Wp,-H256000
720
721### (2) For HP-UX 10.20 using the HP cc, with X11R6 and Motif 1.2, with
722###	libraries in /usr/lib instead of /lib (avoiding transition links).
723###	Information provided by: David Green
724#XROOT = /usr
725#CONF_OPT_X = --x-include=$(XROOT)/include/X11R6 --x-libraries=$(XROOT)/lib/X11R6
726#GUI_INC_LOC = -I/usr/include/Motif1.2
727#GUI_LIB_LOC = -L/usr/lib/Motif1.2_R6
728
729### (5) AIX 4.1.4 with cc
730#CFLAGS = -O -qmaxmem=8192
731
732###     AIX with c89 (Walter Briscoe)
733#CC = c89
734#CPPFLAGS = -D_ALL_SOURCE
735
736###     AIX 4.3.3.12 with xic 3.6.6 (David R. Favor)
737#       needed to avoid a problem where strings.h gets included
738#CFLAGS = -qsrcmsg -O2 -qmaxmem=8192 -D__STR31__
739
740### (W) Solaris with multi-threaded libraries (-lthread):
741###	If suspending doesn't work properly, try using this line:
742#EXTRA_DEFS = -D_REENTRANT
743
744### (7) Solaris 2.4/2.5 with Centerline compiler
745#CC = clcc
746#X_LIBS_DIR = -L/usr/openwin/lib -R/usr/openwin/lib
747#CFLAGS = -O
748
749### (9) Solaris 2.x with cc (SunPro), using Athena.
750###	Only required for compiling gui_at_sb.c.
751###	Symptom: "identifier redeclared: vim_XawScrollbarSetThumb"
752###	Use one of the lines (either Full ANSI or no ANSI at all)
753#CFLAGS = $(CFLAGS) -Xc
754#CFLAGS = $(CFLAGS) -Xs
755
756### Solaris 2.3 with X11 and specific cc
757#CC=/opt/SUNWspro/bin/cc -O -Xa -v -R/usr/openwin/lib
758
759### Solaris with /usr/ucb/cc (it is rejected by autoconf as "cc")
760#CC	    = /usr/ucb/cc
761#EXTRA_LIBS = -R/usr/ucblib
762
763### Solaris with Forte Developer and FEAT_SUN_WORKSHOP
764# The Xpm library is available from http://koala.ilog.fr/ftp/pub/xpm.
765#CC		= cc
766#XPM_DIR		= /usr/local/xpm/xpm-3.4k-solaris
767#XPM_LIB		= -L$(XPM_DIR)/lib -R$(XPM_DIR)/lib -lXpm
768#XPM_IPATH	= -I$(XPM_DIR)/include
769#EXTRA_LIBS	= $(XPM_LIB)
770#EXTRA_IPATHS	= $(XPM_IPATH)
771#EXTRA_DEFS	= -xCC -DHAVE_X11_XPM_H
772
773### Solaris with workshop compilers: Vim is unstable when compiled with
774# "-fast".  Use this instead. (Shea Martin)
775#CFLAGS = -x02 -xtarget=ultra
776
777### (R) for Solaris 2.5 (or 2.5.1) with gcc > 2.5.6 you might need this:
778#LDFLAGS = -lw -ldl -lXmu
779#GUI_LIB_LOC = -L/usr/local/lib
780
781### (8) Unisys 6035 (Glauber Ribeiro)
782#EXTRA_LIBS = -lnsl -lsocket -lgen
783
784### When builtin functions cause problems with gcc (for Sun 4.1.x)
785#CFLAGS = -O2 -Wall -traditional -Wno-implicit
786
787### Apollo DOMAIN (with SYSTYPE = bsd4.3) (TESTED for version 3.0)
788#EXTRA_DEFS = -DDOMAIN
789#CFLAGS= -O -A systype,bsd4.3
790
791### Coherent 4.2.10 on Intel 386 platform
792#EXTRA_DEFS = -Dvoid=int
793#EXTRA_LIBS = -lterm -lsocket
794
795### SCO 3.2, with different library name for terminfo
796#EXTRA_LIBS = -ltinfo
797
798### UTS2 for Amdahl UTS 2.1.x
799#EXTRA_DEFS = -DUTS2
800#EXTRA_LIBS = -lsocket
801
802### UTS4 for Amdahl UTS 4.x
803#EXTRA_DEFS = -DUTS4 -Xa
804
805### USL for Unix Systems Laboratories (SYSV 4.2)
806#EXTRA_DEFS = -DUSL
807
808### (6)  A/UX 3.1.1 with gcc (Jim Jagielski)
809#CC= gcc -D_POSIX_SOURCE
810#CFLAGS= -O2
811#EXTRA_LIBS = -lposix -lbsd -ltermcap -lX11
812
813### (A)  Some versions of SCO Open Server 5 (Jan Christiaan van Winkel)
814###	 Also use the CONF_TERM_LIB below!
815#EXTRA_LIBS = -lgen
816
817### (D)  QNX (by G.F. Desrochers)
818#CFLAGS = -g -O -mf -4
819
820### (F)  QNX (by John Oleynick)
821# 1. If you don't have an X server: Comment out CONF_OPT_GUI and uncomment
822#    CONF_OPT_X = --without-x.
823# 2. make config
824# 3. edit auto/config.mk and remove -ldir and -ltermcap from LIBS.  It doesn't
825#	have -ldir (does config find it somewhere?) and -ltermcap has at
826#	least one problem so I use termlib.o instead.  The problem with
827#	termcap is that it segfaults if you call it with the name of
828#	a non-existent terminal type.
829# 4. edit auto/config.h and add #define USE_TMPNAM
830# 5. add termlib.o to OBJ
831# 6. make
832
833### (H)  for Data general DG/UX 5.4.2 and 5.4R3.10 (Jonas J. Schlein)
834#EXTRA_LIBS = -lgen
835
836### (I) SINIX-N 5.42 or 5.43 RM400 R4000 (also SINIX-Y and SINIX-Z)
837#EXTRA_LIBS = -lgen -lnsl
838###   For SINIX-Y this is needed for the right prototype of gettimeofday()
839#EXTRA_DEFS = -D_XPG_IV
840
841### (I) Reliant-Unix (aka SINIX) 5.44 with standard cc
842#	Use both "-F O3" lines for optimization or the "-g" line for debugging
843#EXTRA_LIBS = -lgen -lsocket -lnsl -lSM -lICE
844#CFLAGS = -F O3 -DSINIXN
845#LDFLAGS = -F O3
846#CFLAGS = -g -DSINIXN
847
848### (P)  SCO 3.2.42, with different termcap names for some useful keys DJB
849#EXTRA_DEFS = -DSCOKEYS -DNETTERM_MOUSE -DDEC_MOUSE -DXTERM_MOUSE -DHAVE_GETTIMEOFDAY
850#EXTRA_LIBS = -lsocket -ltermcap -lmalloc -lc_s
851
852### (P)  SuperUX 6.2 on NEC SX-4 (Lennart Schultz)
853#GUI_INC_LOC = -I/usr/include
854#GUI_LIB_LOC = -L/usr/lib
855#EXTRA_LIBS = -lgen
856
857### (Q) UNIXSVR 4.2MP on NEC UP4800 (Lennart Schultz)
858#GUI_INC_LOC = -I/usr/necccs/include
859#GUI_LIB_LOC = -L/usr/necccs/lib/X11R6
860#XROOT = /usr/necccs
861#CONF_OPT_X = --x-include=$(XROOT)/include --x-libraries=$(XROOT)/lib/X11R6
862#EXTRA_LIBS = -lsocket -lgen
863
864### Irix 4.0 & 5.2 (Silicon Graphics Machines, __sgi will be defined)
865# Not needed for Irix 5.3, Ives Aerts reported
866#EXTRA_LIBS = -lmalloc -lc_s
867# Irix 4.0, when regexp and regcmp cannot be found when linking:
868#EXTRA_LIBS = -lmalloc -lc_s -lPW
869
870### (S) Irix 6.x (MipsPro compiler): Uses different Olimit flag:
871# Note:	This newer option style is used with the MipsPro compilers ONLY if
872#	you are compiling an "n32" or "64" ABI binary (use either a -n32
873#	flag or a -64 flag for CFLAGS).  If you explicitly use a -o32 flag,
874#	then the CFLAGS option format will be the typical style (i.e.
875#	-Olimit 3000).
876#CFLAGS = -OPT:Olimit=3000 -O
877
878### (S) Irix 6.5 with MipsPro C compiler.  Try this as a test to see new
879#	compiler features!  Beware, the optimization is EXTREMELY thorough
880#	and takes quite a long time.
881# Note: See the note above.  Here, the -mips3 option automatically
882#	enables either the "n32" or "64" ABI, depending on what machine you
883#	are compiling on (n32 is explicitly enabled here, just to make sure).
884#CFLAGS = -OPT:Olimit=3500 -O -n32 -mips3 -IPA:aggr_cprop=ON -INLINE:dfe=ON:list=ON:must=screen_char,out_char,ui_write,out_flush
885#LDFLAGS= -OPT:Olimit=3500 -O -n32 -mips3 -IPA:aggr_cprop=ON -INLINE:dfe=ON:list=ON:must=screen_char,out_char,ui_write,out_flush
886
887### (K) for SGI Irix machines with 64 bit pointers ("uname -s" says IRIX64)
888###	Suggested by Jon Wright <[email protected]>.
889###	Tested on R8000 IRIX6.1 Power Indigo2.
890###	Check /etc/compiler.defaults for your compiler settings.
891# either (for 64 bit pointers) uncomment the following line
892#GUI_LIB_LOC = -L/usr/lib64
893# then
894# 1) make config
895# 2) edit auto/config.mk and delete the -lelf entry in the LIBS line
896# 3) make
897#
898# or (for 32bit pointers) uncomment the following line
899#EXTRA_DEFS = -n32
900#GUI_LIB_LOC = -L/usr/lib32
901# then
902# 1) make config
903# 2) edit auto/config.mk, add -n32 to LDFLAGS
904# 3) make
905#
906#Alternatively: use -o32 instead of -n32.
907###
908
909### (C)  On SCO Unix v3.2.5 (and probably other versions) the termcap library,
910###	 which is found by configure, doesn't work correctly.  Symptom is the
911###	 error message "Termcap entry too long".  Uncomment the next line.
912###	 On AIX 4.2.1 (and other versions probably), libtermcap is reported
913###	 not to display properly.
914### after changing this, you need to do "make reconfig".
915#CONF_TERM_LIB = --with-tlib=curses
916
917### (E)  If you want to use termlib library instead of the automatically found
918###	 one.  After changing this, you need to do "make reconfig".
919#CONF_TERM_LIB = --with-tlib=termlib
920
921### (a)  ESIX V4.2 (Reinhard Wobst)
922#EXTRA_LIBS = -lnsl -lsocket -lgen -lXIM -lXmu -lXext
923
924### (c)  Tandem/NSK (Matthew Woehlke)
925#EXTRA_LIBS = -lfloss
926
927### If you want to use ncurses library instead of the automatically found one
928### after changing this, you need to do "make reconfig".
929#CONF_TERM_LIB = --with-tlib=ncurses
930
931### For GCC on MS-Windows, the ".exe" suffix will be added.
932#EXEEXT = .exe
933#LNKEXT = .exe
934
935### (O)  For LynxOS 2.5.0, tested on PC.
936#EXTRA_LIBS = -lXext -lSM -lICE -lbsd
937###	 For LynxOS 3.0.1, tested on PPC
938#EXTRA_LIBS= -lXext -lSM -lICE -lnetinet -lXmu -liberty -lX11
939###	 For LynxOS 3.1.0, tested on PC
940#EXTRA_LIBS= -lXext -lSM -lICE -lnetinet -lXmu
941
942
943### (V)  For CX/UX 6.2	(on Harris/Concurrent NightHawk 4800, 5800). Remove
944###	 -Qtarget if only in a 5800 environment.  (Kipp E. Howard)
945#CFLAGS = -O -Qtarget=m88110compat
946#EXTRA_LIBS = -lgen
947
948# The value of QUOTESED comes from auto/config.mk.
949# Uncomment the next line to use the default value.
950# QUOTESED = sed -e 's/[\\"]/\\&/g' -e 's/\\"/"/' -e 's/\\";$$/";/'
951
952##################### end of system specific lines ################### }}}
953
954### Names of the programs and targets  {{{1
955VIMTARGET	= $(VIMNAME)$(EXEEXT)
956EXTARGET	= $(EXNAME)$(LNKEXT)
957VIEWTARGET	= $(VIEWNAME)$(LNKEXT)
958GVIMNAME	= g$(VIMNAME)
959GVIMTARGET	= $(GVIMNAME)$(LNKEXT)
960GVIEWNAME	= g$(VIEWNAME)
961GVIEWTARGET	= $(GVIEWNAME)$(LNKEXT)
962RVIMNAME	= r$(VIMNAME)
963RVIMTARGET	= $(RVIMNAME)$(LNKEXT)
964RVIEWNAME	= r$(VIEWNAME)
965RVIEWTARGET	= $(RVIEWNAME)$(LNKEXT)
966RGVIMNAME	= r$(GVIMNAME)
967RGVIMTARGET	= $(RGVIMNAME)$(LNKEXT)
968RGVIEWNAME	= r$(GVIEWNAME)
969RGVIEWTARGET	= $(RGVIEWNAME)$(LNKEXT)
970VIMDIFFNAME	= $(VIMNAME)diff
971GVIMDIFFNAME	= g$(VIMDIFFNAME)
972VIMDIFFTARGET	= $(VIMDIFFNAME)$(LNKEXT)
973GVIMDIFFTARGET	= $(GVIMDIFFNAME)$(LNKEXT)
974EVIMNAME	= e$(VIMNAME)
975EVIMTARGET	= $(EVIMNAME)$(LNKEXT)
976EVIEWNAME	= e$(VIEWNAME)
977EVIEWTARGET	= $(EVIEWNAME)$(LNKEXT)
978
979### Names of the tools that are also made  {{{1
980TOOLS = xxd/xxd$(EXEEXT)
981
982### Installation directories.  The defaults come from configure. {{{1
983#
984### prefix	the top directory for the data (default "/usr/local")
985#
986# Uncomment the next line to install Vim in your home directory.
987#prefix = $(HOME)
988
989### exec_prefix	is the top directory for the executable (default $(prefix))
990#
991# Uncomment the next line to install the Vim executable in "/usr/machine/bin"
992#exec_prefix = /usr/machine
993
994### BINDIR	dir for the executable	 (default "$(exec_prefix)/bin")
995### MANDIR	dir for the manual pages (default "$(prefix)/man")
996### DATADIR	dir for the other files  (default "$(prefix)/lib" or
997#						  "$(prefix)/share")
998# They may be different when using different architectures for the
999# executable and a common directory for the other files.
1000#
1001# Uncomment the next line to install Vim in "/usr/bin"
1002#BINDIR   = /usr/bin
1003# Uncomment the next line to install Vim manuals in "/usr/share/man/man1"
1004#MANDIR   = /usr/share/man
1005# Uncomment the next line to install Vim help files in "/usr/share/vim"
1006#DATADIR  = /usr/share
1007
1008### DESTDIR	root of the installation tree.  This is prepended to the other
1009#		directories.  This directory must exist.
1010#DESTDIR  = ~/pkg/vim
1011
1012### Directory of the man pages
1013MAN1DIR = /man1
1014
1015### Vim version (adjusted by a script)
1016VIMMAJOR = 8
1017VIMMINOR = 0
1018
1019### Location of Vim files (should not need to be changed, and  {{{1
1020### some things might not work when they are changed!)
1021VIMDIR = /vim
1022VIMRTDIR = /vim$(VIMMAJOR)$(VIMMINOR)
1023HELPSUBDIR = /doc
1024COLSUBDIR = /colors
1025SYNSUBDIR = /syntax
1026INDSUBDIR = /indent
1027AUTOSUBDIR = /autoload
1028PLUGSUBDIR = /plugin
1029FTPLUGSUBDIR = /ftplugin
1030LANGSUBDIR = /lang
1031COMPSUBDIR = /compiler
1032KMAPSUBDIR = /keymap
1033MACROSUBDIR = /macros
1034PACKSUBDIR = /pack
1035TOOLSSUBDIR = /tools
1036TUTORSUBDIR = /tutor
1037SPELLSUBDIR = /spell
1038PRINTSUBDIR = /print
1039PODIR = po
1040
1041### VIMLOC	common root of the Vim files (all versions)
1042### VIMRTLOC	common root of the runtime Vim files (this version)
1043### VIMRCLOC	compiled-in location for global [g]vimrc files (all versions)
1044### VIMRUNTIMEDIR  compiled-in location for runtime files (optional)
1045### HELPSUBLOC	location for help files
1046### COLSUBLOC	location for colorscheme files
1047### SYNSUBLOC	location for syntax files
1048### INDSUBLOC	location for indent files
1049### AUTOSUBLOC	location for standard autoload files
1050### PLUGSUBLOC	location for standard plugin files
1051### FTPLUGSUBLOC  location for ftplugin files
1052### LANGSUBLOC	location for language files
1053### COMPSUBLOC	location for compiler files
1054### KMAPSUBLOC	location for keymap files
1055### MACROSUBLOC	location for macro files
1056### PACKSUBLOC	location for packages
1057### TOOLSSUBLOC	location for tools files
1058### TUTORSUBLOC	location for tutor files
1059### SPELLSUBLOC	location for spell files
1060### PRINTSUBLOC	location for PostScript files (prolog, latin1, ..)
1061### SCRIPTLOC	location for script files (menu.vim, bugreport.vim, ..)
1062### You can override these if you want to install them somewhere else.
1063### Edit feature.h for compile-time settings.
1064VIMLOC		= $(DATADIR)$(VIMDIR)
1065VIMRTLOC	= $(DATADIR)$(VIMDIR)$(VIMRTDIR)
1066VIMRCLOC	= $(VIMLOC)
1067HELPSUBLOC	= $(VIMRTLOC)$(HELPSUBDIR)
1068COLSUBLOC	= $(VIMRTLOC)$(COLSUBDIR)
1069SYNSUBLOC	= $(VIMRTLOC)$(SYNSUBDIR)
1070INDSUBLOC	= $(VIMRTLOC)$(INDSUBDIR)
1071AUTOSUBLOC	= $(VIMRTLOC)$(AUTOSUBDIR)
1072PLUGSUBLOC	= $(VIMRTLOC)$(PLUGSUBDIR)
1073FTPLUGSUBLOC	= $(VIMRTLOC)$(FTPLUGSUBDIR)
1074LANGSUBLOC	= $(VIMRTLOC)$(LANGSUBDIR)
1075COMPSUBLOC	= $(VIMRTLOC)$(COMPSUBDIR)
1076KMAPSUBLOC	= $(VIMRTLOC)$(KMAPSUBDIR)
1077MACROSUBLOC	= $(VIMRTLOC)$(MACROSUBDIR)
1078PACKSUBLOC	= $(VIMRTLOC)$(PACKSUBDIR)
1079TOOLSSUBLOC	= $(VIMRTLOC)$(TOOLSSUBDIR)
1080TUTORSUBLOC	= $(VIMRTLOC)$(TUTORSUBDIR)
1081SPELLSUBLOC	= $(VIMRTLOC)$(SPELLSUBDIR)
1082PRINTSUBLOC	= $(VIMRTLOC)$(PRINTSUBDIR)
1083SCRIPTLOC	= $(VIMRTLOC)
1084
1085### Only set VIMRUNTIMEDIR when VIMRTLOC is set to a different location and
1086### the runtime directory is not below it.
1087#VIMRUNTIMEDIR = $(VIMRTLOC)
1088
1089### Name of the defaults/evim/mswin file target.
1090VIM_DEFAULTS_FILE = $(DESTDIR)$(SCRIPTLOC)/defaults.vim
1091EVIM_FILE	= $(DESTDIR)$(SCRIPTLOC)/evim.vim
1092MSWIN_FILE	= $(DESTDIR)$(SCRIPTLOC)/mswin.vim
1093
1094### Name of the menu file target.
1095SYS_MENU_FILE	= $(DESTDIR)$(SCRIPTLOC)/menu.vim
1096SYS_SYNMENU_FILE = $(DESTDIR)$(SCRIPTLOC)/synmenu.vim
1097SYS_DELMENU_FILE = $(DESTDIR)$(SCRIPTLOC)/delmenu.vim
1098
1099### Name of the bugreport file target.
1100SYS_BUGR_FILE	= $(DESTDIR)$(SCRIPTLOC)/bugreport.vim
1101
1102### Name of the rgb.txt file target.
1103SYS_RGB_FILE   = $(DESTDIR)$(SCRIPTLOC)/rgb.txt
1104
1105### Name of the file type detection file target.
1106SYS_FILETYPE_FILE = $(DESTDIR)$(SCRIPTLOC)/filetype.vim
1107
1108### Name of the file type detection file target.
1109SYS_FTOFF_FILE	= $(DESTDIR)$(SCRIPTLOC)/ftoff.vim
1110
1111### Name of the file type detection script file target.
1112SYS_SCRIPTS_FILE = $(DESTDIR)$(SCRIPTLOC)/scripts.vim
1113
1114### Name of the ftplugin-on file target.
1115SYS_FTPLUGIN_FILE = $(DESTDIR)$(SCRIPTLOC)/ftplugin.vim
1116
1117### Name of the ftplugin-off file target.
1118SYS_FTPLUGOF_FILE = $(DESTDIR)$(SCRIPTLOC)/ftplugof.vim
1119
1120### Name of the indent-on file target.
1121SYS_INDENT_FILE = $(DESTDIR)$(SCRIPTLOC)/indent.vim
1122
1123### Name of the indent-off file target.
1124SYS_INDOFF_FILE = $(DESTDIR)$(SCRIPTLOC)/indoff.vim
1125
1126### Name of the option window script file target.
1127SYS_OPTWIN_FILE = $(DESTDIR)$(SCRIPTLOC)/optwin.vim
1128
1129# Program to install the program in the target directory.  Could also be "mv".
1130INSTALL_PROG	= cp
1131
1132# Program to install the data in the target directory.	Cannot be "mv"!
1133INSTALL_DATA	= cp
1134INSTALL_DATA_R	= cp -r
1135
1136### Program to run on installed binary.  Use the second one to disable strip.
1137#STRIP = strip
1138#STRIP = /bin/true
1139
1140### Permissions for binaries  {{{1
1141BINMOD = 755
1142
1143### Permissions for man page
1144MANMOD = 644
1145
1146### Permissions for help files
1147HELPMOD = 644
1148
1149### Permissions for Perl and shell scripts
1150SCRIPTMOD = 755
1151
1152### Permission for Vim script files (menu.vim, bugreport.vim, ..)
1153VIMSCRIPTMOD = 644
1154
1155### Permissions for all directories that are created
1156DIRMOD = 755
1157
1158### Permissions for all other files that are created
1159FILEMOD = 644
1160
1161# Where to copy the man and help files from
1162HELPSOURCE = ../runtime/doc
1163
1164# Where to copy the script files from (menu, bugreport)
1165SCRIPTSOURCE = ../runtime
1166
1167# Where to copy the colorscheme files from
1168COLSOURCE = ../runtime/colors
1169
1170# Where to copy the syntax files from
1171SYNSOURCE = ../runtime/syntax
1172
1173# Where to copy the indent files from
1174INDSOURCE = ../runtime/indent
1175
1176# Where to copy the standard plugin files from
1177AUTOSOURCE = ../runtime/autoload
1178
1179# Where to copy the standard plugin files from
1180PLUGSOURCE = ../runtime/plugin
1181
1182# Where to copy the ftplugin files from
1183FTPLUGSOURCE = ../runtime/ftplugin
1184
1185# Where to copy the macro files from
1186MACROSOURCE = ../runtime/macros
1187
1188# Where to copy the package files from
1189PACKSOURCE = ../runtime/pack
1190
1191# Where to copy the tools files from
1192TOOLSSOURCE = ../runtime/tools
1193
1194# Where to copy the tutor files from
1195TUTORSOURCE = ../runtime/tutor
1196
1197# Where to copy the spell files from
1198SPELLSOURCE = ../runtime/spell
1199
1200# Where to look for language specific files
1201LANGSOURCE = ../runtime/lang
1202
1203# Where to look for compiler files
1204COMPSOURCE = ../runtime/compiler
1205
1206# Where to look for keymap files
1207KMAPSOURCE = ../runtime/keymap
1208
1209# Where to look for print resource files
1210PRINTSOURCE = ../runtime/print
1211
1212# If you are using Linux, you might want to use this to make vim the
1213# default vi editor, it will create a link from vi to Vim when doing
1214# "make install".  An existing file will be overwritten!
1215# When not using it, some make programs can't handle an undefined $(LINKIT).
1216#LINKIT = ln -f -s $(DEST_BIN)/$(VIMTARGET) $(DESTDIR)/usr/bin/vi
1217LINKIT = @echo >/dev/null
1218
1219###
1220### GRAPHICAL USER INTERFACE (GUI).  {{{1
1221### 'configure --enable-gui' can enable one of these for you if you did set
1222### a corresponding CONF_OPT_GUI above and have X11.
1223### Override configures choice by uncommenting all the following lines.
1224### As they are, the GUI is disabled.  Replace "NONE" with "ATHENA" or "MOTIF"
1225### for enabling the Athena or Motif GUI.
1226#GUI_SRC	= $(NONE_SRC)
1227#GUI_OBJ	= $(NONE_OBJ)
1228#GUI_DEFS	= $(NONE_DEFS)
1229#GUI_IPATH	= $(NONE_IPATH)
1230#GUI_LIBS_DIR	= $(NONE_LIBS_DIR)
1231#GUI_LIBS1	= $(NONE_LIBS1)
1232#GUI_LIBS2	= $(NONE_LIBS2)
1233#GUI_INSTALL    = $(NONE_INSTALL)
1234#GUI_TARGETS	= $(NONE_TARGETS)
1235#GUI_MAN_TARGETS= $(NONE_MAN_TARGETS)
1236#GUI_TESTTARGET = $(NONE_TESTTARGET)
1237#GUI_BUNDLE	= $(NONE_BUNDLE)
1238
1239# Without a GUI install the normal way.
1240NONE_INSTALL = install_normal
1241
1242### GTK GUI
1243GTK_SRC		= gui.c gui_gtk.c gui_gtk_x11.c pty.c gui_gtk_f.c \
1244			gui_beval.c $(GRESOURCE_SRC)
1245GTK_OBJ		= objects/gui.o objects/gui_gtk.o objects/gui_gtk_x11.o \
1246			objects/pty.o objects/gui_gtk_f.o \
1247			objects/gui_beval.o $(GRESOURCE_OBJ)
1248GTK_DEFS	= -DFEAT_GUI_GTK $(NARROW_PROTO)
1249GTK_IPATH	= $(GUI_INC_LOC)
1250GTK_LIBS_DIR	= $(GUI_LIB_LOC)
1251GTK_LIBS1	=
1252GTK_LIBS2	= $(GTK_LIBNAME)
1253GTK_INSTALL     = install_normal install_gui_extra
1254GTK_TARGETS	= installglinks
1255GTK_MAN_TARGETS = yes
1256GTK_TESTTARGET  = gui
1257GTK_BUNDLE	=
1258
1259### Motif GUI
1260MOTIF_SRC	= gui.c gui_motif.c gui_x11.c pty.c gui_beval.c \
1261			gui_xmdlg.c gui_xmebw.c
1262MOTIF_OBJ	= objects/gui.o objects/gui_motif.o objects/gui_x11.o \
1263			objects/pty.o objects/gui_beval.o \
1264			objects/gui_xmdlg.o objects/gui_xmebw.o
1265MOTIF_DEFS	= -DFEAT_GUI_MOTIF $(NARROW_PROTO)
1266MOTIF_IPATH	= $(GUI_INC_LOC)
1267MOTIF_LIBS_DIR	= $(GUI_LIB_LOC)
1268MOTIF_LIBS1	=
1269MOTIF_LIBS2	= $(MOTIF_LIBNAME) -lXt
1270MOTIF_INSTALL   = install_normal install_gui_extra
1271MOTIF_TARGETS	= installglinks
1272MOTIF_MAN_TARGETS = yes
1273MOTIF_TESTTARGET = gui
1274MOTIF_BUNDLE	=
1275
1276### Athena GUI
1277### Use Xaw3d to make the menus look a little bit nicer
1278#XAW_LIB = -lXaw3d
1279XAW_LIB = -lXaw
1280
1281### When using Xaw3d, uncomment/comment the following lines to also get the
1282### scrollbars from Xaw3d.
1283#ATHENA_SRC	= gui.c gui_athena.c gui_x11.c pty.c gui_beval.c gui_at_fs.c
1284#ATHENA_OBJ	= objects/gui.o objects/gui_athena.o objects/gui_x11.o \
1285#			objects/pty.o objects/gui_beval.o objects/gui_at_fs.o
1286#ATHENA_DEFS	= -DFEAT_GUI_ATHENA $(NARROW_PROTO) \
1287#		    -Dvim_scrollbarWidgetClass=scrollbarWidgetClass \
1288#		    -Dvim_XawScrollbarSetThumb=XawScrollbarSetThumb
1289ATHENA_SRC	= gui.c gui_athena.c gui_x11.c pty.c gui_beval.c \
1290			gui_at_sb.c gui_at_fs.c
1291ATHENA_OBJ	= objects/gui.o objects/gui_athena.o objects/gui_x11.o \
1292			objects/pty.o objects/gui_beval.o \
1293			objects/gui_at_sb.o objects/gui_at_fs.o
1294ATHENA_DEFS	= -DFEAT_GUI_ATHENA $(NARROW_PROTO)
1295
1296ATHENA_IPATH	= $(GUI_INC_LOC)
1297ATHENA_LIBS_DIR = $(GUI_LIB_LOC)
1298ATHENA_LIBS1	= $(XAW_LIB)
1299ATHENA_LIBS2	= -lXt
1300ATHENA_INSTALL  = install_normal install_gui_extra
1301ATHENA_TARGETS	= installglinks
1302ATHENA_MAN_TARGETS = yes
1303ATHENA_TESTTARGET = gui
1304ATHENA_BUNDLE	=
1305
1306### neXtaw GUI
1307NEXTAW_LIB = -lneXtaw
1308
1309NEXTAW_SRC	= gui.c gui_athena.c gui_x11.c pty.c gui_beval.c gui_at_fs.c
1310NEXTAW_OBJ	= objects/gui.o objects/gui_athena.o objects/gui_x11.o \
1311			objects/pty.o objects/gui_beval.o objects/gui_at_fs.o
1312NEXTAW_DEFS	= -DFEAT_GUI_ATHENA -DFEAT_GUI_NEXTAW $(NARROW_PROTO)
1313
1314NEXTAW_IPATH	= $(GUI_INC_LOC)
1315NEXTAW_LIBS_DIR = $(GUI_LIB_LOC)
1316NEXTAW_LIBS1	= $(NEXTAW_LIB)
1317NEXTAW_LIBS2	= -lXt
1318NEXTAW_INSTALL  =  install_normal install_gui_extra
1319NEXTAW_TARGETS	=  installglinks
1320NEXTAW_MAN_TARGETS = yes
1321NEXTAW_TESTTARGET = gui
1322NEXTAW_BUNDLE	=
1323
1324### (J)  Sun OpenWindows 3.2 (SunOS 4.1.x) or earlier that produce these ld
1325#	 errors:  ld: Undefined symbol
1326#		      _get_wmShellWidgetClass
1327#		      _get_applicationShellWidgetClass
1328# then you need to get patches 100512-02 and 100573-03 from Sun.  In the
1329# meantime, uncomment the following GUI_X_LIBS definition as a workaround:
1330#GUI_X_LIBS = -Bstatic -lXmu -Bdynamic -lXext
1331# If you also get cos, sin etc. as undefined symbols, try uncommenting this
1332# too:
1333#EXTRA_LIBS = /usr/openwin/lib/libXmu.sa -lm
1334
1335# PHOTON GUI
1336PHOTONGUI_SRC	= gui.c gui_photon.c pty.c
1337PHOTONGUI_OBJ	= objects/gui.o objects/gui_photon.o objects/pty.o
1338PHOTONGUI_DEFS	= -DFEAT_GUI_PHOTON
1339PHOTONGUI_IPATH	=
1340PHOTONGUI_LIBS_DIR =
1341PHOTONGUI_LIBS1	= -lph -lphexlib
1342PHOTONGUI_LIBS2	=
1343PHOTONGUI_INSTALL = install_normal install_gui_extra
1344PHOTONGUI_TARGETS = installglinks
1345PHOTONGUI_MAN_TARGETS = yes
1346PHOTONGUI_TESTTARGET = gui
1347PHOTONGUI_BUNDLE =
1348
1349# CARBON GUI
1350CARBONGUI_SRC	= gui.c gui_mac.c
1351CARBONGUI_OBJ	= objects/gui.o objects/gui_mac.o objects/pty.o
1352CARBONGUI_DEFS	= -DFEAT_GUI_MAC -fno-common -fpascal-strings \
1353		  -Wall -Wno-unknown-pragmas \
1354		  -mdynamic-no-pic -pipe
1355CARBONGUI_IPATH	= -I. -Iproto
1356CARBONGUI_LIBS_DIR =
1357CARBONGUI_LIBS1	= -framework Carbon
1358CARBONGUI_LIBS2	=
1359CARBONGUI_INSTALL = install_macosx
1360CARBONGUI_TARGETS =
1361CARBONGUI_MAN_TARGETS =
1362CARBONGUI_TESTTARGET = gui
1363CARBONGUI_BUNDLE = gui_bundle
1364APPDIR = $(VIMNAME).app
1365CARBONGUI_TESTARG = VIMPROG=../$(APPDIR)/Contents/MacOS/$(VIMTARGET)
1366
1367# All GUI files
1368ALL_GUI_SRC  = gui.c gui_gtk.c gui_gtk_f.c gui_motif.c gui_xmdlg.c gui_xmebw.c gui_athena.c gui_gtk_x11.c gui_x11.c gui_at_sb.c gui_at_fs.c pty.c
1369ALL_GUI_PRO  = gui.pro gui_gtk.pro gui_motif.pro gui_xmdlg.pro gui_athena.pro gui_gtk_x11.pro gui_x11.pro gui_w32.pro gui_photon.pro
1370
1371# }}}
1372
1373### Command to create dependencies based on #include "..."
1374### prototype headers are ignored due to -DPROTO, system
1375### headers #include <...> are ignored if we use the -MM option, as
1376### e.g. provided by gcc-cpp.
1377### Include FEAT_GUI to get dependency on gui.h
1378### Need to change "-I /<path>" to "-isystem /<path>" for GCC 3.x.
1379CPP_DEPEND = $(CC) -I$(srcdir) -M$(CPP_MM) \
1380		`echo "$(DEPEND_CFLAGS)" $(DEPEND_CFLAGS_FILTER)`
1381
1382# flags for cproto
1383#     This is for cproto 3 patchlevel 8 or below
1384#     __inline, __attribute__ and __extension__ are not recognized by cproto
1385#     G_IMPLEMENT_INLINES is to avoid functions defined in glib/gutils.h.
1386#NO_ATTR = -D__inline= -D__inline__= -DG_IMPLEMENT_INLINES \
1387#	  -D"__attribute__\\(x\\)=" -D"__asm__\\(x\\)=" \
1388#	  -D__extension__= -D__restrict="" \
1389#	  -D__gnuc_va_list=char -D__builtin_va_list=char
1390
1391#
1392#     This is for cproto 3 patchlevel 9 or above (currently 4.6, 4.7g)
1393#     __inline and __attribute__ are now recognized by cproto
1394#     -D"foo()=" is not supported by all compilers so do not use it
1395NO_ATTR=
1396#
1397# Use this for cproto 3 patchlevel 6 or below (use "cproto -V" to check):
1398# PROTO_FLAGS = -f4 -d -E"$(CPP)" $(NO_ATTR)
1399#
1400# Use this for cproto 3 patchlevel 7 or above (use "cproto -V" to check):
1401PROTO_FLAGS = -d -E"$(CPP)" $(NO_ATTR)
1402
1403
1404################################################
1405##   no changes required below this line      ##
1406################################################
1407
1408SHELL = /bin/sh
1409
1410.SUFFIXES:
1411.SUFFIXES: .c .o .pro
1412
1413PRE_DEFS = -Iproto $(DEFS) $(GUI_DEFS) $(GUI_IPATH) $(CPPFLAGS) $(EXTRA_IPATHS)
1414POST_DEFS = $(X_CFLAGS) $(MZSCHEME_CFLAGS) $(EXTRA_DEFS)
1415
1416ALL_CFLAGS = $(PRE_DEFS) $(CFLAGS) $(PROFILE_CFLAGS) $(SANITIZER_CFLAGS) $(LEAK_CFLAGS) $(ABORT_CLFAGS) $(POST_DEFS)
1417
1418# Exclude $CFLAGS for osdef.sh, for Mac 10.4 some flags don't work together
1419# with "-E".
1420OSDEF_CFLAGS = $(PRE_DEFS) $(POST_DEFS)
1421
1422LINT_CFLAGS = -DLINT -I. $(PRE_DEFS) $(POST_DEFS) $(RUBY_CFLAGS) $(LUA_CFLAGS) $(PERL_CFLAGS) $(PYTHON_CFLAGS) $(PYTHON3_CFLAGS) $(TCL_CFLAGS) -Dinline= -D__extension__= -Dalloca=alloca
1423
1424LINT_EXTRA = -DHANGUL_INPUT -D"__attribute__(x)="
1425
1426DEPEND_CFLAGS = -DPROTO -DDEPEND -DFEAT_GUI $(LINT_CFLAGS)
1427
1428# Note: MZSCHEME_LIBS must come before LIBS, because LIBS adds -lm which is
1429# needed by racket.
1430ALL_LIB_DIRS = $(GUI_LIBS_DIR) $(X_LIBS_DIR)
1431ALL_LIBS = \
1432	   $(GUI_LIBS1) \
1433	   $(GUI_X_LIBS) \
1434	   $(GUI_LIBS2) \
1435	   $(X_PRE_LIBS) \
1436	   $(X_LIBS) \
1437	   $(X_EXTRA_LIBS) \
1438	   $(MZSCHEME_LIBS) \
1439	   $(LIBS) \
1440	   $(EXTRA_LIBS) \
1441	   $(LUA_LIBS) \
1442	   $(PERL_LIBS) \
1443	   $(PYTHON_LIBS) \
1444	   $(PYTHON3_LIBS) \
1445	   $(TCL_LIBS) \
1446	   $(RUBY_LIBS) \
1447	   $(PROFILE_LIBS) \
1448	   $(SANITIZER_LIBS) \
1449	   $(LEAK_LIBS)
1450
1451# abbreviations
1452DEST_BIN = $(DESTDIR)$(BINDIR)
1453DEST_VIM = $(DESTDIR)$(VIMLOC)
1454DEST_RT = $(DESTDIR)$(VIMRTLOC)
1455DEST_HELP = $(DESTDIR)$(HELPSUBLOC)
1456DEST_COL = $(DESTDIR)$(COLSUBLOC)
1457DEST_SYN = $(DESTDIR)$(SYNSUBLOC)
1458DEST_IND = $(DESTDIR)$(INDSUBLOC)
1459DEST_AUTO = $(DESTDIR)$(AUTOSUBLOC)
1460DEST_PLUG = $(DESTDIR)$(PLUGSUBLOC)
1461DEST_FTP = $(DESTDIR)$(FTPLUGSUBLOC)
1462DEST_LANG = $(DESTDIR)$(LANGSUBLOC)
1463DEST_COMP = $(DESTDIR)$(COMPSUBLOC)
1464DEST_KMAP = $(DESTDIR)$(KMAPSUBLOC)
1465DEST_MACRO = $(DESTDIR)$(MACROSUBLOC)
1466DEST_PACK = $(DESTDIR)$(PACKSUBLOC)
1467DEST_TOOLS = $(DESTDIR)$(TOOLSSUBLOC)
1468DEST_TUTOR = $(DESTDIR)$(TUTORSUBLOC)
1469DEST_SPELL = $(DESTDIR)$(SPELLSUBLOC)
1470DEST_SCRIPT = $(DESTDIR)$(SCRIPTLOC)
1471DEST_PRINT = $(DESTDIR)$(PRINTSUBLOC)
1472DEST_MAN_TOP = $(DESTDIR)$(MANDIR)
1473
1474# We assume that the ".../man/xx/man1/" directory is for latin1 manual pages.
1475# Some systems use UTF-8, but these should find the ".../man/xx.UTF-8/man1/"
1476# directory first.
1477# FreeBSD uses ".../man/xx.ISO8859-1/man1" for latin1, use that one too.
1478DEST_MAN = $(DEST_MAN_TOP)$(MAN1DIR)
1479DEST_MAN_FR = $(DEST_MAN_TOP)/fr$(MAN1DIR)
1480DEST_MAN_FR_I = $(DEST_MAN_TOP)/fr.ISO8859-1$(MAN1DIR)
1481DEST_MAN_FR_U = $(DEST_MAN_TOP)/fr.UTF-8$(MAN1DIR)
1482DEST_MAN_IT = $(DEST_MAN_TOP)/it$(MAN1DIR)
1483DEST_MAN_IT_I = $(DEST_MAN_TOP)/it.ISO8859-1$(MAN1DIR)
1484DEST_MAN_IT_U = $(DEST_MAN_TOP)/it.UTF-8$(MAN1DIR)
1485DEST_MAN_JA_U = $(DEST_MAN_TOP)/ja$(MAN1DIR)
1486DEST_MAN_PL = $(DEST_MAN_TOP)/pl$(MAN1DIR)
1487DEST_MAN_PL_I = $(DEST_MAN_TOP)/pl.ISO8859-2$(MAN1DIR)
1488DEST_MAN_PL_U = $(DEST_MAN_TOP)/pl.UTF-8$(MAN1DIR)
1489DEST_MAN_RU = $(DEST_MAN_TOP)/ru.KOI8-R$(MAN1DIR)
1490DEST_MAN_RU_U = $(DEST_MAN_TOP)/ru.UTF-8$(MAN1DIR)
1491
1492#	     BASIC_SRC: files that are always used
1493#	       GUI_SRC: extra GUI files for current configuration
1494#	   ALL_GUI_SRC: all GUI files for Unix
1495#
1496#		   SRC: files used for current configuration
1497#	      TAGS_SRC: source files used for make tags
1498#	     TAGS_INCL: include files used for make tags
1499#	       ALL_SRC: source files used for make depend and make lint
1500
1501TAGS_INCL = *.h
1502
1503BASIC_SRC = \
1504	arabic.c \
1505	blowfish.c \
1506	buffer.c \
1507	charset.c \
1508	crypt.c \
1509	crypt_zip.c \
1510	dict.c \
1511	diff.c \
1512	digraph.c \
1513	edit.c \
1514	eval.c \
1515	evalfunc.c \
1516	ex_cmds.c \
1517	ex_cmds2.c \
1518	ex_docmd.c \
1519	ex_eval.c \
1520	ex_getln.c \
1521	farsi.c \
1522	fileio.c \
1523	fold.c \
1524	getchar.c \
1525	hardcopy.c \
1526	hashtab.c \
1527	if_cscope.c \
1528	if_xcmdsrv.c \
1529	json.c \
1530	list.c \
1531	main.c \
1532	mark.c \
1533	memfile.c \
1534	memline.c \
1535	menu.c \
1536	message.c \
1537	misc1.c \
1538	misc2.c \
1539	move.c \
1540	mbyte.c \
1541	normal.c \
1542	ops.c \
1543	option.c \
1544	os_unix.c \
1545	auto/pathdef.c \
1546	popupmnu.c \
1547	quickfix.c \
1548	regexp.c \
1549	screen.c \
1550	search.c \
1551	sha256.c \
1552	spell.c \
1553	spellfile.c \
1554	syntax.c \
1555	tag.c \
1556	term.c \
1557	ui.c \
1558	undo.c \
1559	userfunc.c \
1560	version.c \
1561	window.c \
1562	$(OS_EXTRA_SRC)
1563
1564SRC =	$(BASIC_SRC) \
1565	$(GUI_SRC) \
1566	$(HANGULIN_SRC) \
1567	$(LUA_SRC) \
1568	$(MZSCHEME_SRC) \
1569	$(PERL_SRC) \
1570	$(PYTHON_SRC) $(PYTHON3_SRC) \
1571	$(TCL_SRC) \
1572	$(RUBY_SRC) \
1573	$(WORKSHOP_SRC) \
1574	$(WSDEBUG_SRC)
1575
1576TAGS_SRC = *.c *.cpp if_perl.xs
1577
1578EXTRA_SRC = hangulin.c if_lua.c if_mzsch.c auto/if_perl.c if_perlsfio.c \
1579	    if_python.c if_python3.c if_tcl.c if_ruby.c \
1580	    gui_beval.c workshop.c wsdebug.c integration.c \
1581	    netbeans.c channel.c \
1582	    $(GRESOURCE_SRC)
1583
1584# Unittest files
1585JSON_TEST_SRC = json_test.c
1586JSON_TEST_TARGET = json_test$(EXEEXT)
1587KWORD_TEST_SRC = kword_test.c
1588KWORD_TEST_TARGET = kword_test$(EXEEXT)
1589MEMFILE_TEST_SRC = memfile_test.c
1590MEMFILE_TEST_TARGET = memfile_test$(EXEEXT)
1591MESSAGE_TEST_SRC = message_test.c
1592MESSAGE_TEST_TARGET = message_test$(EXEEXT)
1593
1594UNITTEST_SRC = $(JSON_TEST_SRC) $(KWORD_TEST_SRC) $(MEMFILE_TEST_SRC) $(MESSAGE_TEST_SRC)
1595UNITTEST_TARGETS = $(JSON_TEST_TARGET) $(KWORD_TEST_TARGET) $(MEMFILE_TEST_TARGET) $(MESSAGE_TEST_TARGET)
1596RUN_UNITTESTS = run_json_test run_kword_test run_memfile_test run_message_test
1597
1598# All sources, also the ones that are not configured
1599ALL_SRC = $(BASIC_SRC) $(ALL_GUI_SRC) $(UNITTEST_SRC) $(EXTRA_SRC)
1600
1601# Which files to check with lint.  Select one of these three lines.  ALL_SRC
1602# checks more, but may not work well for checking a GUI that wasn't configured.
1603# The perl sources also don't work well with lint.
1604LINT_SRC = $(BASIC_SRC) $(GUI_SRC) $(HANGULIN_SRC) \
1605	   $(PYTHON_SRC) $(PYTHON3_SRC) $(TCL_SRC) \
1606	   $(WORKSHOP_SRC) $(WSDEBUG_SRC) \
1607	   $(NETBEANS_SRC) $(CHANNEL_SRC)
1608#LINT_SRC = $(SRC)
1609#LINT_SRC = $(ALL_SRC)
1610#LINT_SRC = $(BASIC_SRC)
1611
1612OBJ_COMMON = \
1613	objects/arabic.o \
1614	objects/buffer.o \
1615	objects/blowfish.o \
1616	objects/crypt.o \
1617	objects/crypt_zip.o \
1618	objects/dict.o \
1619	objects/diff.o \
1620	objects/digraph.o \
1621	objects/edit.o \
1622	objects/eval.o \
1623	objects/evalfunc.o \
1624	objects/ex_cmds.o \
1625	objects/ex_cmds2.o \
1626	objects/ex_docmd.o \
1627	objects/ex_eval.o \
1628	objects/ex_getln.o \
1629	objects/farsi.o \
1630	objects/fileio.o \
1631	objects/fold.o \
1632	objects/getchar.o \
1633	objects/hardcopy.o \
1634	objects/hashtab.o \
1635	$(HANGULIN_OBJ) \
1636	objects/if_cscope.o \
1637	objects/if_xcmdsrv.o \
1638	objects/list.o \
1639	objects/mark.o \
1640	objects/memline.o \
1641	objects/menu.o \
1642	objects/misc1.o \
1643	objects/misc2.o \
1644	objects/move.o \
1645	objects/mbyte.o \
1646	objects/normal.o \
1647	objects/ops.o \
1648	objects/option.o \
1649	objects/os_unix.o \
1650	objects/pathdef.o \
1651	objects/popupmnu.o \
1652	objects/quickfix.o \
1653	objects/regexp.o \
1654	objects/screen.o \
1655	objects/search.o \
1656	objects/sha256.o \
1657	objects/spell.o \
1658	objects/spellfile.o \
1659	objects/syntax.o \
1660	objects/tag.o \
1661	objects/term.o \
1662	objects/ui.o \
1663	objects/undo.o \
1664	objects/userfunc.o \
1665	objects/version.o \
1666	objects/window.o \
1667	$(GUI_OBJ) \
1668	$(LUA_OBJ) \
1669	$(MZSCHEME_OBJ) \
1670	$(PERL_OBJ) \
1671	$(PYTHON_OBJ) \
1672	$(PYTHON3_OBJ) \
1673	$(TCL_OBJ) \
1674	$(RUBY_OBJ) \
1675	$(OS_EXTRA_OBJ) \
1676	$(WORKSHOP_OBJ) \
1677	$(NETBEANS_OBJ) \
1678	$(CHANNEL_OBJ) \
1679	$(WSDEBUG_OBJ)
1680
1681# The files included by tests are not in OBJ_COMMON.
1682OBJ_MAIN = \
1683	objects/charset.o \
1684	objects/json.o \
1685	objects/main.o \
1686	objects/memfile.o \
1687	objects/message.o
1688
1689OBJ = $(OBJ_COMMON) $(OBJ_MAIN)
1690
1691OBJ_JSON_TEST = \
1692	objects/charset.o \
1693	objects/memfile.o \
1694	objects/message.o \
1695	objects/json_test.o
1696
1697JSON_TEST_OBJ = $(OBJ_COMMON) $(OBJ_JSON_TEST)
1698
1699OBJ_KWORD_TEST = \
1700	objects/json.o \
1701	objects/memfile.o \
1702	objects/message.o \
1703	objects/kword_test.o
1704
1705KWORD_TEST_OBJ = $(OBJ_COMMON) $(OBJ_KWORD_TEST)
1706
1707OBJ_MEMFILE_TEST = \
1708	objects/charset.o \
1709	objects/json.o \
1710	objects/message.o \
1711	objects/memfile_test.o
1712
1713MEMFILE_TEST_OBJ = $(OBJ_COMMON) $(OBJ_MEMFILE_TEST)
1714
1715OBJ_MESSAGE_TEST = \
1716	objects/charset.o \
1717	objects/json.o \
1718	objects/memfile.o \
1719	objects/message_test.o
1720
1721MESSAGE_TEST_OBJ = $(OBJ_COMMON) $(OBJ_MESSAGE_TEST)
1722
1723ALL_OBJ = $(OBJ_COMMON) \
1724	  $(OBJ_MAIN) \
1725	  $(OBJ_JSON_TEST) \
1726	  $(OBJ_KWORD_TEST) \
1727	  $(OBJ_MEMFILE_TEST) \
1728	  $(OBJ_MESSAGE_TEST)
1729
1730
1731PRO_AUTO = \
1732	arabic.pro \
1733	blowfish.pro \
1734	buffer.pro \
1735	charset.pro \
1736	crypt.pro \
1737	crypt_zip.pro \
1738	dict.pro \
1739	diff.pro \
1740	digraph.pro \
1741	edit.pro \
1742	eval.pro \
1743	evalfunc.pro \
1744	ex_cmds.pro \
1745	ex_cmds2.pro \
1746	ex_docmd.pro \
1747	ex_eval.pro \
1748	ex_getln.pro \
1749	farsi.pro \
1750	fileio.pro \
1751	fold.pro \
1752	getchar.pro \
1753	hardcopy.pro \
1754	hashtab.pro \
1755	hangulin.pro \
1756	if_cscope.pro \
1757	if_lua.pro \
1758	if_mzsch.pro \
1759	if_python.pro \
1760	if_python3.pro \
1761	if_ruby.pro \
1762	if_xcmdsrv.pro \
1763	json.pro \
1764	list.pro \
1765	main.pro \
1766	mark.pro \
1767	mbyte.pro \
1768	memfile.pro \
1769	memline.pro \
1770	menu.pro \
1771	message.pro \
1772	misc1.pro \
1773	misc2.pro \
1774	move.pro \
1775	normal.pro \
1776	ops.pro \
1777	option.pro \
1778	os_mac_conv.pro \
1779	os_unix.pro \
1780	popupmnu.pro \
1781	pty.pro \
1782	quickfix.pro \
1783	regexp.pro \
1784	screen.pro \
1785	search.pro \
1786	sha256.pro \
1787	spell.pro \
1788	spellfile.pro \
1789	syntax.pro \
1790	tag.pro \
1791	term.pro \
1792	termlib.pro \
1793	ui.pro \
1794	undo.pro \
1795	userfunc.pro \
1796	version.pro \
1797	window.pro \
1798	gui_beval.pro \
1799	workshop.pro \
1800	netbeans.pro \
1801	channel.pro \
1802	$(ALL_GUI_PRO) \
1803	$(TCL_PRO)
1804
1805# Resources used for the Mac are in one directory.
1806RSRC_DIR = os_mac_rsrc
1807
1808PRO_MANUAL = os_amiga.pro os_win32.pro \
1809	os_mswin.pro winclip.pro os_beos.pro os_vms.pro $(PERL_PRO)
1810
1811# Default target is making the executable and tools
1812all: $(VIMTARGET) $(TOOLS) languages $(GUI_BUNDLE)
1813
1814tools: $(TOOLS)
1815
1816# Run configure with all the setting from above.
1817#
1818# Note: auto/config.h doesn't depend on configure, because running configure
1819# doesn't always update auto/config.h.  The timestamp isn't changed if the
1820# file contents didn't change (to avoid recompiling everything).  Including a
1821# dependency on auto/config.h would cause running configure each time when
1822# auto/config.h isn't updated.  The dependency on auto/config.mk should make
1823# sure configure is run when it's needed.
1824#
1825# Remove the config.cache every time, once in a while it causes problems that
1826# are very hard to figure out.
1827#
1828config auto/config.mk: auto/configure config.mk.in config.h.in
1829	-rm -f auto/config.cache
1830	if test "X$(MAKECMDGOALS)" != "Xclean" \
1831		-a "X$(MAKECMDGOALS)" != "Xdistclean" \
1832		-a "X$(MAKECMDGOALS)" != "Xautoconf" \
1833		-a "X$(MAKECMDGOALS)" != "Xreconfig"; then \
1834	    GUI_INC_LOC="$(GUI_INC_LOC)" GUI_LIB_LOC="$(GUI_LIB_LOC)" \
1835		CC="$(CC)" CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS)" \
1836		LDFLAGS="$(LDFLAGS)" $(CONF_SHELL) srcdir="$(srcdir)" \
1837		./configure $(CONF_OPT_GUI) $(CONF_OPT_X) $(CONF_OPT_XSMP) \
1838		$(CONF_OPT_DARWIN) $(CONF_OPT_FAIL) \
1839		$(CONF_OPT_PERL) $(CONF_OPT_PYTHON) $(CONF_OPT_PYTHON3) \
1840		$(CONF_OPT_TCL) $(CONF_OPT_RUBY) $(CONF_OPT_NLS) \
1841		$(CONF_OPT_CSCOPE) $(CONF_OPT_MULTIBYTE) $(CONF_OPT_INPUT) \
1842		$(CONF_OPT_OUTPUT) $(CONF_OPT_GPM) $(CONF_OPT_WORKSHOP) \
1843		$(CONF_OPT_FEAT) $(CONF_TERM_LIB) \
1844		$(CONF_OPT_COMPBY) $(CONF_OPT_ACL) $(CONF_OPT_NETBEANS) \
1845		$(CONF_OPT_CHANNEL) \
1846		$(CONF_ARGS) $(CONF_OPT_MZSCHEME) $(CONF_OPT_PLTHOME) \
1847		$(CONF_OPT_LUA) $(CONF_OPT_LUA_PREFIX) \
1848		$(CONF_OPT_SYSMOUSE); \
1849	fi
1850
1851# Use "make reconfig" to rerun configure without cached values.
1852# When config.h changes, most things will be recompiled automatically.
1853# Invoke $(MAKE) to run config with the empty auto/config.mk.
1854# Invoke $(MAKE) to build all with the filled auto/config.mk.
1855reconfig: scratch clean
1856	$(MAKE) -f Makefile config
1857	$(MAKE) -f Makefile all
1858
1859# Run autoconf to produce auto/configure.
1860# Note:
1861# - DO NOT RUN autoconf MANUALLY!  It will overwrite ./configure instead of
1862#   producing auto/configure.
1863# - autoconf is not run automatically, because a patch usually changes both
1864#   configure.ac and auto/configure but can't update the timestamps.  People
1865#   who do not have (the correct version of) autoconf would run into trouble.
1866#
1867# Two tricks are required to make autoconf put its output in the "auto" dir:
1868# - Temporarily move the ./configure script to ./configure.save.  Don't
1869#   overwrite it, it's probably the result of an aborted autoconf.
1870# - Use sed to change ./config.log to auto/config.log in the configure script.
1871# Autoconf 2.5x (2.59 at least) produces a few more files that we need to take
1872# care of:
1873# - configure.lineno: has the line numbers replaced with $LINENO.  That
1874#   improves patches a LOT, thus use it instead (until someone says it doesn't
1875#   work on some system).
1876# - autom4te.cache directory is created and not cleaned up.  Delete it.
1877# - Uses ">config.log" instead of "./config.log".
1878autoconf:
1879	if test ! -f configure.save; then mv configure configure.save; fi
1880	$(AUTOCONF)
1881	sed -e 's+>config.log+>auto/config.log+' -e 's+\./config.log+auto/config.log+' configure > auto/configure
1882	chmod 755 auto/configure
1883	mv -f configure.save configure
1884	-rm -rf autom4te.cache
1885	-rm -f auto/config.status auto/config.cache
1886
1887# Re-execute this Makefile to include the new auto/config.mk produced by
1888# configure Only used when typing "make" with a fresh auto/config.mk.
1889myself:
1890	$(MAKE) -f Makefile all
1891
1892
1893# The normal command to compile a .c file to its .o file.
1894# Without or with ALL_CFLAGS.
1895CCC_NF = $(CC) -c -I$(srcdir)
1896CCC = $(CCC_NF) $(ALL_CFLAGS)
1897
1898
1899# Link the target for normal use or debugging.
1900# A shell script is used to try linking without unnecessary libraries.
1901$(VIMTARGET): auto/config.mk objects $(OBJ) version.c version.h
1902	$(CCC) version.c -o objects/version.o
1903	@LINK="$(PURIFY) $(SHRPENV) $(CClink) $(ALL_LIB_DIRS) $(LDFLAGS) \
1904		-o $(VIMTARGET) $(OBJ) $(ALL_LIBS)" \
1905		MAKE="$(MAKE)" LINK_AS_NEEDED=$(LINK_AS_NEEDED) \
1906		sh $(srcdir)/link.sh
1907
1908xxd/xxd$(EXEEXT): xxd/xxd.c
1909	cd xxd; CC="$(CC)" CFLAGS="$(CPPFLAGS) $(CFLAGS)" LDFLAGS="$(LDFLAGS)" \
1910		$(MAKE) -f Makefile
1911
1912# Build the language specific files if they were unpacked.
1913# Generate the converted .mo files separately, it's no problem if this fails.
1914languages:
1915	@if test -n "$(MAKEMO)" -a -f $(PODIR)/Makefile; then \
1916		cd $(PODIR); \
1917		  CC="$(CC)" $(MAKE) prefix=$(DESTDIR)$(prefix); \
1918	fi
1919	-@if test -n "$(MAKEMO)" -a -f $(PODIR)/Makefile; then \
1920		cd $(PODIR); \
1921		  CC="$(CC)" $(MAKE) prefix=$(DESTDIR)$(prefix) converted; \
1922	fi
1923
1924# Update the *.po files for changes in the sources.  Only run manually.
1925update-po:
1926	cd $(PODIR); CC="$(CC)" $(MAKE) prefix=$(DESTDIR)$(prefix) update-po
1927
1928# Generate function prototypes.  This is not needed to compile vim, but if
1929# you want to use it, cproto is out there on the net somewhere -- Webb
1930#
1931# When generating os_amiga.pro and os_win32.pro there will be a
1932# few include files that can not be found, that's OK.
1933
1934proto: $(PRO_AUTO) $(PRO_MANUAL)
1935
1936# Filter out arguments that cproto doesn't support.
1937# Don't pass "-pthread", "-fwrapv" and similar arguments to cproto, it sees
1938# them as a list of individual flags.
1939# The -E"gcc -E" argument must be separate to avoid problems with shell
1940# quoting.
1941CPROTO = cproto $(PROTO_FLAGS) -DPROTO \
1942	 `echo '$(LINT_CFLAGS)' | sed -e 's/ -[a-z-]\+//g'`
1943
1944### Would be nice if this would work for "normal" make.
1945### Currently it only works for (Free)BSD make.
1946#$(PRO_AUTO): $$(*F).c
1947#	$(CPROTO) -DFEAT_GUI $(*F).c > $@
1948
1949# Always define FEAT_GUI.  This may generate a few warnings if it's also
1950# defined in auto/config.h, you can ignore that.
1951.c.pro:
1952	$(CPROTO) -DFEAT_GUI $< > proto/$@
1953	echo "/* vim: set ft=c : */" >> proto/$@
1954
1955os_amiga.pro: os_amiga.c
1956	$(CPROTO) -DAMIGA -UHAVE_CONFIG_H -DBPTR=char* $< > proto/$@
1957	echo "/* vim: set ft=c : */" >> proto/$@
1958
1959os_win32.pro: os_win32.c
1960	$(CPROTO) -DWIN32 -UHAVE_CONFIG_H $< > proto/$@
1961	echo "/* vim: set ft=c : */" >> proto/$@
1962
1963os_mswin.pro: os_mswin.c
1964	$(CPROTO) -DWIN32 -UHAVE_CONFIG_H $< > proto/$@
1965	echo "/* vim: set ft=c : */" >> proto/$@
1966
1967winclip.pro: winclip.c
1968	$(CPROTO) -DWIN32 -UHAVE_CONFIG_H $< > proto/$@
1969	echo "/* vim: set ft=c : */" >> proto/$@
1970
1971os_beos.pro: os_beos.c
1972	$(CPROTO) -D__BEOS__ -UHAVE_CONFIG_H $< > proto/$@
1973	echo "/* vim: set ft=c : */" >> proto/$@
1974
1975os_vms.pro: os_vms.c
1976# must use os_vms_conf.h for auto/config.h
1977	mv auto/config.h auto/config.h.save
1978	cp os_vms_conf.h auto/config.h
1979	$(CPROTO) -DVMS -UFEAT_GUI_ATHENA -UFEAT_GUI_NEXTAW -UFEAT_GUI_MOTIF -UFEAT_GUI_GTK $< > proto/$@
1980	echo "/* vim: set ft=c : */" >> proto/$@
1981	rm auto/config.h
1982	mv auto/config.h.save auto/config.h
1983
1984# if_perl.pro is special: Use the generated if_perl.c for input and remove
1985# prototypes for local functions.
1986if_perl.pro: auto/if_perl.c
1987	$(CPROTO) -DFEAT_GUI auto/if_perl.c | sed "/_VI/d" > proto/$@
1988
1989gui_gtk_gresources.pro: auto/gui_gtk_gresources.c
1990	$(CPROTO) -DFEAT_GUI $< > proto/$@
1991	echo "/* vim: set ft=c : */" >> proto/$@
1992
1993notags:
1994	-rm -f tags
1995
1996# Note: tags is made for the currently configured version, can't include both
1997#	Motif and Athena GUI
1998# You can ignore error messages for missing files.
1999tags TAGS: notags
2000	$(TAGPRG) $(TAGS_SRC) $(TAGS_INCL)
2001
2002# Make a highlight file for types.  Requires Exuberant ctags and awk
2003types: types.vim
2004types.vim: $(TAGS_SRC) $(TAGS_INCL)
2005	ctags --c-kinds=gstu -o- $(TAGS_SRC) $(TAGS_INCL) |\
2006		awk 'BEGIN{printf("syntax keyword Type\t")}\
2007			{printf("%s ", $$1)}END{print ""}' > $@
2008	echo "syn keyword Constant OK FAIL TRUE FALSE MAYBE" >> $@
2009
2010# TESTING
2011#
2012# Execute the test scripts and the unittests.
2013test check: scripttests unittests
2014
2015# Execute the test scripts.  Run these after compiling Vim, before installing.
2016# This doesn't depend on $(VIMTARGET), because that won't work when configure
2017# wasn't run yet.  Restart make to build it instead.
2018#
2019# This will produce a lot of garbage on your screen, including a few error
2020# messages.  Don't worry about that.
2021# If there is a real error, there will be a difference between "testXX.out" and
2022# a "testXX.ok" file.
2023# If everything is alright, the final message will be "ALL DONE".  If not you
2024# get "TEST FAILURE".
2025#
2026scripttests:
2027	$(MAKE) -f Makefile $(VIMTARGET)
2028	if test -n "$(MAKEMO)" -a -f $(PODIR)/Makefile; then \
2029		cd $(PODIR); $(MAKE) -f Makefile check VIM=../$(VIMTARGET); \
2030	fi
2031	-if test $(VIMTARGET) != vim -a ! -r vim; then \
2032		ln -s $(VIMTARGET) vim; \
2033	fi
2034	cd testdir; $(MAKE) -f Makefile $(GUI_TESTTARGET) VIMPROG=../$(VIMTARGET) $(GUI_TESTARG) SCRIPTSOURCE=../$(SCRIPTSOURCE)
2035
2036
2037# Run the tests with the GUI.  Assumes vim/gvim was already built
2038testgui:
2039	cd testdir; $(MAKE) -f Makefile $(GUI_TESTTARGET) VIMPROG=../$(VIMTARGET) GUI_FLAG=-g $(GUI_TESTARG) SCRIPTSOURCE=../$(SCRIPTSOURCE)
2040
2041benchmark:
2042	cd testdir; $(MAKE) -f Makefile benchmark VIMPROG=../$(VIMTARGET) SCRIPTSOURCE=../$(SCRIPTSOURCE)
2043
2044unittesttargets:
2045	$(MAKE) -f Makefile $(UNITTEST_TARGETS)
2046
2047# Execute the unittests one by one.
2048unittest unittests: $(RUN_UNITTESTS)
2049
2050run_json_test: $(JSON_TEST_TARGET)
2051	$(VALGRIND) ./$(JSON_TEST_TARGET) || exit 1; echo $* passed;
2052
2053run_kword_test: $(KWORD_TEST_TARGET)
2054	$(VALGRIND) ./$(KWORD_TEST_TARGET) || exit 1; echo $* passed;
2055
2056run_memfile_test: $(MEMFILE_TEST_TARGET)
2057	$(VALGRIND) ./$(MEMFILE_TEST_TARGET) || exit 1; echo $* passed;
2058
2059run_message_test: $(MESSAGE_TEST_TARGET)
2060	$(VALGRIND) ./$(MESSAGE_TEST_TARGET) || exit 1; echo $* passed;
2061
2062# Run individual OLD style test, assuming that Vim was already compiled.
2063test1 \
2064	test_autocmd_option \
2065	test_autoformat_join \
2066	test_changelist \
2067	test_close_count \
2068	test_comparators \
2069	test_erasebackword \
2070	test_eval \
2071	test_fixeol \
2072	test_getcwd \
2073	test_insertcount \
2074	test_listchars \
2075	test_search_mbyte \
2076	test_wordcount \
2077	test3 test4 test5 test6 test7 test8 test9 \
2078	test11 test12 test14 test15 test17 test18 test19 \
2079	test20 test21 test22 test23 test24 test25 test26 test27 test28 test29 \
2080	test30 test31 test32 test33 test34 test36 test37 test38 test39 \
2081	test40 test41 test42 test43 test44 test45 test48 test49 \
2082	test50 test51 test52 test53 test54 test55 test56 test57 test58 test59 \
2083	test60 test64 test65 test66 test67 test68 test69 \
2084	test70 test72 test73 test74 test75 test77 test78 test79 \
2085	test80 test82 test83 test84 test85 test86 test87 test88 test89 \
2086	test90 test91 test94 test95 test97 test98 test99 \
2087	test100 test101 test103 test104 test107 test108:
2088	cd testdir; rm -f $@.out; $(MAKE) -f Makefile $@.out VIMPROG=../$(VIMTARGET) $(GUI_TESTARG) SCRIPTSOURCE=../$(SCRIPTSOURCE)
2089
2090# Run individual NEW style test, assuming that Vim was already compiled.
2091test_arglist \
2092	test_assert \
2093	test_assign \
2094	test_autochdir \
2095	test_autocmd \
2096	test_backspace_opt \
2097	test_breakindent \
2098	test_bufwintabinfo \
2099	test_cdo \
2100	test_channel \
2101	test_charsearch \
2102	test_cmdline \
2103	test_command_count \
2104	test_crypt \
2105	test_cscope \
2106	test_cursor_func \
2107	test_delete \
2108	test_diffmode \
2109	test_digraph \
2110	test_functions \
2111	test_display \
2112	test_ex_undo \
2113	test_execute_func \
2114	test_expand \
2115	test_expand_dllpath \
2116	test_expr \
2117	test_expr_utf8 \
2118	test_farsi \
2119	test_feedkeys \
2120	test_file_perm \
2121	test_fileformat \
2122	test_filter_cmd \
2123	test_filter_map \
2124	test_float_func \
2125	test_fnameescape \
2126	test_fnamemodify \
2127	test_fold \
2128	test_ga \
2129	test_gf \
2130	test_glob2regpat \
2131	test_gn \
2132	test_goto \
2133	test_gui \
2134	test_hardcopy \
2135	test_help_tagjump \
2136	test_hide \
2137	test_history \
2138	test_hlsearch \
2139	test_increment \
2140	test_increment_dbcs \
2141	test_job_fails \
2142	test_join \
2143	test_json \
2144	test_jumps \
2145	test_lambda \
2146	test_langmap \
2147	test_largefile \
2148	test_lispwords \
2149	test_listlbr \
2150	test_listlbr_utf8 \
2151	test_lua \
2152	test_man \
2153	test_mapping \
2154	test_marks \
2155	test_match \
2156	test_matchadd_conceal \
2157	test_matchadd_conceal_utf8 \
2158	test_menu \
2159	test_messages \
2160	test_mksession \
2161	test_mksession_utf8 \
2162	test_nested_function \
2163	test_netbeans \
2164	test_normal \
2165	test_options \
2166	test_packadd \
2167	test_partial \
2168	test_paste \
2169	test_perl \
2170	test_popup \
2171	test_profile \
2172	test_put \
2173	test_python2 \
2174	test_python3 \
2175	test_pyx2 \
2176	test_pyx3 \
2177	test_quickfix \
2178	test_regexp_latin \
2179	test_regexp_utf8 \
2180	test_reltime \
2181	test_retab \
2182	test_ruby \
2183	test_search \
2184	test_searchpos \
2185	test_set \
2186	test_signs \
2187	test_smartindent \
2188	test_sort \
2189	test_source_utf8 \
2190	test_startup \
2191	test_startup_utf8 \
2192	test_stat \
2193	test_statusline \
2194	test_substitute \
2195	test_syn_attr \
2196	test_syntax \
2197	test_system \
2198	test_tabline \
2199	test_tabpage \
2200	test_tagcase \
2201	test_tagjump \
2202	test_tcl \
2203	test_textobjects \
2204	test_timers \
2205	test_true_false \
2206	test_undo \
2207	test_unlet \
2208	test_usercommands \
2209	test_utf8 \
2210	test_viminfo \
2211	test_viml \
2212	test_visual \
2213	test_window_cmd \
2214	test_window_id \
2215	test_writefile \
2216	test_alot_latin \
2217	test_alot_utf8 \
2218	test_alot:
2219	cd testdir; rm -f $@.res test.log messages; $(MAKE) -f Makefile $@.res VIMPROG=../$(VIMTARGET) $(GUI_TESTARG) SCRIPTSOURCE=../$(SCRIPTSOURCE)
2220	@if test -f testdir/test.log; then \
2221		cat testdir/test.log; \
2222	fi
2223	cat testdir/messages
2224
2225newtests:
2226	cd testdir; rm -f $@.res test.log messages; $(MAKE) -f Makefile newtestssilent VIMPROG=../$(VIMTARGET) $(GUI_TESTARG) SCRIPTSOURCE=../$(SCRIPTSOURCE)
2227	@if test -f testdir/test.log; then \
2228		cat testdir/test.log; \
2229	fi
2230	cat testdir/messages
2231
2232testclean:
2233	cd testdir; $(MAKE) -f Makefile clean
2234	if test -d $(PODIR); then \
2235		cd $(PODIR); $(MAKE) checkclean; \
2236	fi
2237
2238# Unittests
2239# It's build just like Vim to satisfy all dependencies.
2240$(JSON_TEST_TARGET): auto/config.mk objects $(JSON_TEST_OBJ)
2241	$(CCC) version.c -o objects/version.o
2242	@LINK="$(PURIFY) $(SHRPENV) $(CClink) $(ALL_LIB_DIRS) $(LDFLAGS) \
2243		-o $(JSON_TEST_TARGET) $(JSON_TEST_OBJ) $(ALL_LIBS)" \
2244		MAKE="$(MAKE)" LINK_AS_NEEDED=$(LINK_AS_NEEDED) \
2245		sh $(srcdir)/link.sh
2246
2247$(KWORD_TEST_TARGET): auto/config.mk objects $(KWORD_TEST_OBJ)
2248	$(CCC) version.c -o objects/version.o
2249	@LINK="$(PURIFY) $(SHRPENV) $(CClink) $(ALL_LIB_DIRS) $(LDFLAGS) \
2250		-o $(KWORD_TEST_TARGET) $(KWORD_TEST_OBJ) $(ALL_LIBS)" \
2251		MAKE="$(MAKE)" LINK_AS_NEEDED=$(LINK_AS_NEEDED) \
2252		sh $(srcdir)/link.sh
2253
2254$(MEMFILE_TEST_TARGET): auto/config.mk objects $(MEMFILE_TEST_OBJ)
2255	$(CCC) version.c -o objects/version.o
2256	@LINK="$(PURIFY) $(SHRPENV) $(CClink) $(ALL_LIB_DIRS) $(LDFLAGS) \
2257		-o $(MEMFILE_TEST_TARGET) $(MEMFILE_TEST_OBJ) $(ALL_LIBS)" \
2258		MAKE="$(MAKE)" LINK_AS_NEEDED=$(LINK_AS_NEEDED) \
2259		sh $(srcdir)/link.sh
2260
2261$(MESSAGE_TEST_TARGET): auto/config.mk objects $(MESSAGE_TEST_OBJ)
2262	$(CCC) version.c -o objects/version.o
2263	@LINK="$(PURIFY) $(SHRPENV) $(CClink) $(ALL_LIB_DIRS) $(LDFLAGS) \
2264		-o $(MESSAGE_TEST_TARGET) $(MESSAGE_TEST_OBJ) $(ALL_LIBS)" \
2265		MAKE="$(MAKE)" LINK_AS_NEEDED=$(LINK_AS_NEEDED) \
2266		sh $(srcdir)/link.sh
2267
2268# install targets
2269
2270install: $(GUI_INSTALL)
2271
2272install_normal: installvim installtools $(INSTALL_LANGS) install-icons
2273
2274install_gui_extra: installgtutorbin
2275
2276installvim: installvimbin installtutorbin \
2277		installruntime installlinks installmanlinks
2278
2279#
2280# Avoid overwriting an existing executable, somebody might be running it and
2281# overwriting it could cause it to crash.  Deleting it is OK, it won't be
2282# really deleted until all running processes for it have exited.  It is
2283# renamed first, in case the deleting doesn't work.
2284#
2285# If you want to keep an older version, rename it before running "make
2286# install".
2287#
2288installvimbin: $(VIMTARGET) $(DESTDIR)$(exec_prefix) $(DEST_BIN)
2289	-if test -f $(DEST_BIN)/$(VIMTARGET); then \
2290	  mv -f $(DEST_BIN)/$(VIMTARGET) $(DEST_BIN)/$(VIMNAME).rm; \
2291	  rm -f $(DEST_BIN)/$(VIMNAME).rm; \
2292	fi
2293	$(INSTALL_PROG) $(VIMTARGET) $(DEST_BIN)
2294	$(STRIP) $(DEST_BIN)/$(VIMTARGET)
2295	chmod $(BINMOD) $(DEST_BIN)/$(VIMTARGET)
2296# may create a link to the new executable from /usr/bin/vi
2297	-$(LINKIT)
2298
2299# Long list of arguments for the shell script that installs the manual pages
2300# for one language.
2301INSTALLMANARGS = $(VIMLOC) $(SCRIPTLOC) $(VIMRCLOC) $(HELPSOURCE) $(MANMOD) \
2302		$(VIMNAME) $(VIMDIFFNAME) $(EVIMNAME)
2303
2304# Install most of the runtime files
2305installruntime: installrtbase installmacros installpack installtutor installspell
2306
2307# install the help files; first adjust the contents for the final location
2308installrtbase: $(HELPSOURCE)/vim.1 $(DEST_VIM) $(DEST_RT) \
2309		$(DEST_HELP) $(DEST_PRINT) $(DEST_COL) $(DEST_SYN) $(DEST_IND) \
2310		$(DEST_FTP) $(DEST_AUTO) $(DEST_AUTO)/xml $(DEST_PLUG) \
2311		$(DEST_TUTOR) $(DEST_SPELL) $(DEST_COMP)
2312	-$(SHELL) ./installman.sh install $(DEST_MAN) "" $(INSTALLMANARGS)
2313# Generate the help tags with ":helptags" to handle all languages.
2314# Move the distributed tags file aside and restore it, to avoid it being
2315# different from the repository.
2316	cd $(HELPSOURCE); if test -z "$(CROSS_COMPILING)" -a -f tags; then \
2317		mv -f tags tags.dist; fi
2318	@echo generating help tags
2319	-@cd $(HELPSOURCE); if test -z "$(CROSS_COMPILING)"; then \
2320		$(MAKE) VIMEXE=$(DEST_BIN)/$(VIMTARGET) vimtags; fi
2321	cd $(HELPSOURCE); \
2322		files=`ls *.txt tags`; \
2323		files="$$files `ls *.??x tags-?? 2>/dev/null || true`"; \
2324		$(INSTALL_DATA) $$files  $(DEST_HELP); \
2325		cd $(DEST_HELP); \
2326		chmod $(HELPMOD) $$files
2327	$(INSTALL_DATA)  $(HELPSOURCE)/*.pl $(DEST_HELP)
2328	chmod $(SCRIPTMOD) $(DEST_HELP)/*.pl
2329	cd $(HELPSOURCE); if test -f tags.dist; then mv -f tags.dist tags; fi
2330# install the menu files
2331	$(INSTALL_DATA) $(SCRIPTSOURCE)/menu.vim $(SYS_MENU_FILE)
2332	chmod $(VIMSCRIPTMOD) $(SYS_MENU_FILE)
2333	$(INSTALL_DATA) $(SCRIPTSOURCE)/synmenu.vim $(SYS_SYNMENU_FILE)
2334	chmod $(VIMSCRIPTMOD) $(SYS_SYNMENU_FILE)
2335	$(INSTALL_DATA) $(SCRIPTSOURCE)/delmenu.vim $(SYS_DELMENU_FILE)
2336	chmod $(VIMSCRIPTMOD) $(SYS_DELMENU_FILE)
2337# install the defaults/evim/mswin file
2338	$(INSTALL_DATA) $(SCRIPTSOURCE)/defaults.vim $(VIM_DEFAULTS_FILE)
2339	chmod $(VIMSCRIPTMOD) $(VIM_DEFAULTS_FILE)
2340	$(INSTALL_DATA) $(SCRIPTSOURCE)/evim.vim $(EVIM_FILE)
2341	chmod $(VIMSCRIPTMOD) $(EVIM_FILE)
2342	$(INSTALL_DATA) $(SCRIPTSOURCE)/mswin.vim $(MSWIN_FILE)
2343	chmod $(VIMSCRIPTMOD) $(MSWIN_FILE)
2344# install the rgb.txt file
2345	$(INSTALL_DATA) $(SCRIPTSOURCE)/rgb.txt $(SYS_RGB_FILE)
2346	chmod $(VIMSCRIPTMOD) $(SYS_RGB_FILE)
2347# install the bugreport file
2348	$(INSTALL_DATA) $(SCRIPTSOURCE)/bugreport.vim $(SYS_BUGR_FILE)
2349	chmod $(VIMSCRIPTMOD) $(SYS_BUGR_FILE)
2350# install the example vimrc files
2351	$(INSTALL_DATA) $(SCRIPTSOURCE)/vimrc_example.vim $(DEST_SCRIPT)
2352	chmod $(VIMSCRIPTMOD) $(DEST_SCRIPT)/vimrc_example.vim
2353	$(INSTALL_DATA) $(SCRIPTSOURCE)/gvimrc_example.vim $(DEST_SCRIPT)
2354	chmod $(VIMSCRIPTMOD) $(DEST_SCRIPT)/gvimrc_example.vim
2355# install the file type detection files
2356	$(INSTALL_DATA) $(SCRIPTSOURCE)/filetype.vim $(SYS_FILETYPE_FILE)
2357	chmod $(VIMSCRIPTMOD) $(SYS_FILETYPE_FILE)
2358	$(INSTALL_DATA) $(SCRIPTSOURCE)/ftoff.vim $(SYS_FTOFF_FILE)
2359	chmod $(VIMSCRIPTMOD) $(SYS_FTOFF_FILE)
2360	$(INSTALL_DATA) $(SCRIPTSOURCE)/scripts.vim $(SYS_SCRIPTS_FILE)
2361	chmod $(VIMSCRIPTMOD) $(SYS_SCRIPTS_FILE)
2362	$(INSTALL_DATA) $(SCRIPTSOURCE)/ftplugin.vim $(SYS_FTPLUGIN_FILE)
2363	chmod $(VIMSCRIPTMOD) $(SYS_FTPLUGIN_FILE)
2364	$(INSTALL_DATA) $(SCRIPTSOURCE)/ftplugof.vim $(SYS_FTPLUGOF_FILE)
2365	chmod $(VIMSCRIPTMOD) $(SYS_FTPLUGOF_FILE)
2366	$(INSTALL_DATA) $(SCRIPTSOURCE)/indent.vim $(SYS_INDENT_FILE)
2367	chmod $(VIMSCRIPTMOD) $(SYS_INDENT_FILE)
2368	$(INSTALL_DATA) $(SCRIPTSOURCE)/indoff.vim $(SYS_INDOFF_FILE)
2369	chmod $(VIMSCRIPTMOD) $(SYS_INDOFF_FILE)
2370	$(INSTALL_DATA) $(SCRIPTSOURCE)/optwin.vim $(SYS_OPTWIN_FILE)
2371	chmod $(VIMSCRIPTMOD) $(SYS_OPTWIN_FILE)
2372# install the print resource files
2373	cd $(PRINTSOURCE); $(INSTALL_DATA) *.ps $(DEST_PRINT)
2374	cd $(DEST_PRINT); chmod $(FILEMOD) *.ps
2375# install the colorscheme files
2376	cd $(COLSOURCE); $(INSTALL_DATA) *.vim README.txt $(DEST_COL)
2377	cd $(DEST_COL); chmod $(HELPMOD) *.vim README.txt
2378# install the syntax files
2379	cd $(SYNSOURCE); $(INSTALL_DATA) *.vim README.txt $(DEST_SYN)
2380	cd $(DEST_SYN); chmod $(HELPMOD) *.vim README.txt
2381# install the indent files
2382	cd $(INDSOURCE); $(INSTALL_DATA) *.vim README.txt $(DEST_IND)
2383	cd $(DEST_IND); chmod $(HELPMOD) *.vim README.txt
2384# install the standard autoload files
2385	cd $(AUTOSOURCE); $(INSTALL_DATA) *.vim README.txt $(DEST_AUTO)
2386	cd $(DEST_AUTO); chmod $(HELPMOD) *.vim README.txt
2387	cd $(AUTOSOURCE)/xml; $(INSTALL_DATA) *.vim $(DEST_AUTO)/xml
2388	cd $(DEST_AUTO)/xml; chmod $(HELPMOD) *.vim
2389# install the standard plugin files
2390	cd $(PLUGSOURCE); $(INSTALL_DATA) *.vim README.txt $(DEST_PLUG)
2391	cd $(DEST_PLUG); chmod $(HELPMOD) *.vim README.txt
2392# install the ftplugin files
2393	cd $(FTPLUGSOURCE); $(INSTALL_DATA) *.vim README.txt logtalk.dict $(DEST_FTP)
2394	cd $(DEST_FTP); chmod $(HELPMOD) *.vim README.txt
2395# install the compiler files
2396	cd $(COMPSOURCE); $(INSTALL_DATA) *.vim README.txt $(DEST_COMP)
2397	cd $(DEST_COMP); chmod $(HELPMOD) *.vim README.txt
2398
2399installmacros: $(DEST_VIM) $(DEST_RT) $(DEST_MACRO)
2400	$(INSTALL_DATA_R) $(MACROSOURCE)/* $(DEST_MACRO)
2401	chmod $(DIRMOD) `find $(DEST_MACRO) -type d -print`
2402	chmod $(FILEMOD) `find $(DEST_MACRO) -type f -print`
2403	chmod $(SCRIPTMOD) $(DEST_MACRO)/less.sh
2404# When using CVS some CVS directories might have been copied.
2405# Also delete AAPDIR and *.info files.
2406	cvs=`find $(DEST_MACRO) \( -name CVS -o -name AAPDIR -o -name "*.info" \) -print`; \
2407	      if test -n "$$cvs"; then \
2408		 rm -rf $$cvs; \
2409	      fi
2410
2411installpack: $(DEST_VIM) $(DEST_RT) $(DEST_PACK)
2412	$(INSTALL_DATA_R) $(PACKSOURCE)/* $(DEST_PACK)
2413	chmod $(DIRMOD) `find $(DEST_PACK) -type d -print`
2414	chmod $(FILEMOD) `find $(DEST_PACK) -type f -print`
2415
2416# install the tutor files
2417installtutorbin: $(DEST_VIM)
2418	$(INSTALL_DATA) vimtutor $(DEST_BIN)/$(VIMNAME)tutor
2419	chmod $(SCRIPTMOD) $(DEST_BIN)/$(VIMNAME)tutor
2420
2421installgtutorbin: $(DEST_VIM)
2422	$(INSTALL_DATA) gvimtutor $(DEST_BIN)/$(GVIMNAME)tutor
2423	chmod $(SCRIPTMOD) $(DEST_BIN)/$(GVIMNAME)tutor
2424
2425installtutor: $(DEST_RT) $(DEST_TUTOR)
2426	-$(INSTALL_DATA) $(TUTORSOURCE)/README* $(TUTORSOURCE)/tutor* $(DEST_TUTOR)
2427	-rm -f $(DEST_TUTOR)/*.info
2428	chmod $(HELPMOD) $(DEST_TUTOR)/*
2429
2430# Install the spell files, if they exist.  This assumes at least the English
2431# spell file is there.
2432installspell: $(DEST_VIM) $(DEST_RT) $(DEST_SPELL)
2433	if test -f $(SPELLSOURCE)/en.latin1.spl; then \
2434	  $(INSTALL_DATA) $(SPELLSOURCE)/*.spl $(SPELLSOURCE)/*.sug $(SPELLSOURCE)/*.vim $(DEST_SPELL); \
2435	  chmod $(HELPMOD) $(DEST_SPELL)/*.spl $(DEST_SPELL)/*.sug $(DEST_SPELL)/*.vim; \
2436	fi
2437
2438# install helper program xxd
2439installtools: $(TOOLS) $(DESTDIR)$(exec_prefix) $(DEST_BIN) \
2440		$(TOOLSSOURCE) $(DEST_VIM) $(DEST_RT) $(DEST_TOOLS) \
2441		$(INSTALL_TOOL_LANGS)
2442	if test -f $(DEST_BIN)/xxd$(EXEEXT); then \
2443	  mv -f $(DEST_BIN)/xxd$(EXEEXT) $(DEST_BIN)/xxd.rm; \
2444	  rm -f $(DEST_BIN)/xxd.rm; \
2445	fi
2446	$(INSTALL_PROG) xxd/xxd$(EXEEXT) $(DEST_BIN)
2447	$(STRIP) $(DEST_BIN)/xxd$(EXEEXT)
2448	chmod $(BINMOD) $(DEST_BIN)/xxd$(EXEEXT)
2449	-$(SHELL) ./installman.sh xxd $(DEST_MAN) "" $(INSTALLMANARGS)
2450
2451# install the runtime tools
2452	$(INSTALL_DATA_R) $(TOOLSSOURCE)/* $(DEST_TOOLS)
2453# When using CVS some CVS directories might have been copied.
2454	cvs=`find $(DEST_TOOLS) \( -name CVS -o -name AAPDIR \) -print`; \
2455	      if test -n "$$cvs"; then \
2456		 rm -rf $$cvs; \
2457	      fi
2458	-chmod $(FILEMOD) $(DEST_TOOLS)/*
2459# replace the path in some tools
2460	perlpath=`./which.sh perl` && sed -e "s+/usr/bin/perl+$$perlpath+" $(TOOLSSOURCE)/efm_perl.pl >$(DEST_TOOLS)/efm_perl.pl
2461	awkpath=`./which.sh nawk` && sed -e "s+/usr/bin/nawk+$$awkpath+" $(TOOLSSOURCE)/mve.awk >$(DEST_TOOLS)/mve.awk; if test -z "$$awkpath"; then \
2462		awkpath=`./which.sh gawk` && sed -e "s+/usr/bin/nawk+$$awkpath+" $(TOOLSSOURCE)/mve.awk >$(DEST_TOOLS)/mve.awk; if test -z "$$awkpath"; then \
2463		awkpath=`./which.sh awk` && sed -e "s+/usr/bin/nawk+$$awkpath+" $(TOOLSSOURCE)/mve.awk >$(DEST_TOOLS)/mve.awk; fi; fi
2464	-chmod $(SCRIPTMOD) `grep -l "^#!" $(DEST_TOOLS)/*`
2465
2466# install the language specific files for tools, if they were unpacked
2467install-tool-languages:
2468	-$(SHELL) ./installman.sh xxd $(DEST_MAN_FR) "-fr" $(INSTALLMANARGS)
2469	-$(SHELL) ./installman.sh xxd $(DEST_MAN_FR_I) "-fr" $(INSTALLMANARGS)
2470	-$(SHELL) ./installman.sh xxd $(DEST_MAN_FR_U) "-fr.UTF-8" $(INSTALLMANARGS)
2471	-$(SHELL) ./installman.sh xxd $(DEST_MAN_IT) "-it" $(INSTALLMANARGS)
2472	-$(SHELL) ./installman.sh xxd $(DEST_MAN_IT_I) "-it" $(INSTALLMANARGS)
2473	-$(SHELL) ./installman.sh xxd $(DEST_MAN_IT_U) "-it.UTF-8" $(INSTALLMANARGS)
2474	-$(SHELL) ./installman.sh xxd $(DEST_MAN_JA_U) "-ja.UTF-8" $(INSTALLMANARGS)
2475	-$(SHELL) ./installman.sh xxd $(DEST_MAN_PL) "-pl" $(INSTALLMANARGS)
2476	-$(SHELL) ./installman.sh xxd $(DEST_MAN_PL_I) "-pl" $(INSTALLMANARGS)
2477	-$(SHELL) ./installman.sh xxd $(DEST_MAN_PL_U) "-pl.UTF-8" $(INSTALLMANARGS)
2478	-$(SHELL) ./installman.sh xxd $(DEST_MAN_RU) "-ru" $(INSTALLMANARGS)
2479	-$(SHELL) ./installman.sh xxd $(DEST_MAN_RU_U) "-ru.UTF-8" $(INSTALLMANARGS)
2480
2481# install the language specific files, if they were unpacked
2482install-languages: languages $(DEST_LANG) $(DEST_KMAP)
2483	-$(SHELL) ./installman.sh install $(DEST_MAN_FR) "-fr" $(INSTALLMANARGS)
2484	-$(SHELL) ./installman.sh install $(DEST_MAN_FR_I) "-fr" $(INSTALLMANARGS)
2485	-$(SHELL) ./installman.sh install $(DEST_MAN_FR_U) "-fr.UTF-8" $(INSTALLMANARGS)
2486	-$(SHELL) ./installman.sh install $(DEST_MAN_IT) "-it" $(INSTALLMANARGS)
2487	-$(SHELL) ./installman.sh install $(DEST_MAN_IT_I) "-it" $(INSTALLMANARGS)
2488	-$(SHELL) ./installman.sh install $(DEST_MAN_IT_U) "-it.UTF-8" $(INSTALLMANARGS)
2489	-$(SHELL) ./installman.sh install $(DEST_MAN_JA_U) "-ja.UTF-8" $(INSTALLMANARGS)
2490	-$(SHELL) ./installman.sh install $(DEST_MAN_PL) "-pl" $(INSTALLMANARGS)
2491	-$(SHELL) ./installman.sh install $(DEST_MAN_PL_I) "-pl" $(INSTALLMANARGS)
2492	-$(SHELL) ./installman.sh install $(DEST_MAN_PL_U) "-pl.UTF-8" $(INSTALLMANARGS)
2493	-$(SHELL) ./installman.sh install $(DEST_MAN_RU) "-ru" $(INSTALLMANARGS)
2494	-$(SHELL) ./installman.sh install $(DEST_MAN_RU_U) "-ru.UTF-8" $(INSTALLMANARGS)
2495	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2496		$(DEST_MAN_FR) $(INSTALLMLARGS)
2497	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2498		$(DEST_MAN_FR_I) $(INSTALLMLARGS)
2499	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2500		$(DEST_MAN_FR_U) $(INSTALLMLARGS)
2501	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2502		$(DEST_MAN_IT) $(INSTALLMLARGS)
2503	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2504		$(DEST_MAN_IT_I) $(INSTALLMLARGS)
2505	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2506		$(DEST_MAN_IT_U) $(INSTALLMLARGS)
2507	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2508		$(DEST_MAN_JA_U) $(INSTALLMLARGS)
2509	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2510		$(DEST_MAN_PL) $(INSTALLMLARGS)
2511	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2512		$(DEST_MAN_PL_I) $(INSTALLMLARGS)
2513	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2514		$(DEST_MAN_PL_U) $(INSTALLMLARGS)
2515	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2516		$(DEST_MAN_RU) $(INSTALLMLARGS)
2517	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2518		$(DEST_MAN_RU_U) $(INSTALLMLARGS)
2519	if test -n "$(MAKEMO)" -a -f $(PODIR)/Makefile; then \
2520	   cd $(PODIR); $(MAKE) prefix=$(DESTDIR)$(prefix) LOCALEDIR=$(DEST_LANG) \
2521	   INSTALL_DATA=$(INSTALL_DATA) FILEMOD=$(FILEMOD) install; \
2522	fi
2523	if test -d $(LANGSOURCE); then \
2524	   $(INSTALL_DATA) $(LANGSOURCE)/README.txt $(LANGSOURCE)/*.vim $(DEST_LANG); \
2525	   chmod $(FILEMOD) $(DEST_LANG)/README.txt $(DEST_LANG)/*.vim; \
2526	fi
2527	if test -d $(KMAPSOURCE); then \
2528	   $(INSTALL_DATA) $(KMAPSOURCE)/README.txt $(KMAPSOURCE)/*.vim $(DEST_KMAP); \
2529	   chmod $(FILEMOD) $(DEST_KMAP)/README.txt $(DEST_KMAP)/*.vim; \
2530	fi
2531
2532# Install the icons for KDE, if the directory exists and the icon doesn't.
2533# Always when $(DESTDIR) is not empty.
2534ICON48PATH = $(DESTDIR)$(DATADIR)/icons/hicolor/48x48/apps
2535ICON32PATH = $(DESTDIR)$(DATADIR)/icons/locolor/32x32/apps
2536ICON16PATH = $(DESTDIR)$(DATADIR)/icons/locolor/16x16/apps
2537ICONTHEMEPATH = $(DATADIR)/icons/hicolor
2538DESKTOPPATH = $(DESTDIR)$(DATADIR)/applications
2539KDEPATH = $(HOME)/.kde/share/icons
2540install-icons:
2541	if test -n "$(DESTDIR)"; then \
2542		$(SHELL) ./mkinstalldirs $(ICON48PATH) $(ICON32PATH) \
2543		$(ICON16PATH) $(DESKTOPPATH); \
2544	fi
2545
2546	if test -d $(ICON48PATH) -a -w $(ICON48PATH) \
2547		-a ! -f $(ICON48PATH)/gvim.png; then \
2548	   $(INSTALL_DATA) $(SCRIPTSOURCE)/vim48x48.png $(ICON48PATH)/gvim.png; \
2549	   if test -z "$(DESTDIR)" -a -x "$(GTK_UPDATE_ICON_CACHE)" \
2550		   -a -w $(ICONTHEMEPATH) \
2551		   -a -f $(ICONTHEMEPATH)/index.theme; then \
2552		$(GTK_UPDATE_ICON_CACHE) -q $(ICONTHEMEPATH); \
2553	   fi \
2554	fi
2555	if test -d $(ICON32PATH) -a -w $(ICON32PATH) \
2556		-a ! -f $(ICON32PATH)/gvim.png; then \
2557	   $(INSTALL_DATA) $(SCRIPTSOURCE)/vim32x32.png $(ICON32PATH)/gvim.png; \
2558	fi
2559	if test -d $(ICON16PATH) -a -w $(ICON16PATH) \
2560		-a ! -f $(ICON16PATH)/gvim.png; then \
2561	   $(INSTALL_DATA) $(SCRIPTSOURCE)/vim16x16.png $(ICON16PATH)/gvim.png; \
2562	fi
2563	if test -d $(DESKTOPPATH) -a -w $(DESKTOPPATH); then \
2564	   $(INSTALL_DATA) $(SCRIPTSOURCE)/vim.desktop \
2565		$(SCRIPTSOURCE)/gvim.desktop \
2566		$(DESKTOPPATH); \
2567	   if test -z "$(DESTDIR)" -a -x "$(UPDATE_DESKTOP_DATABASE)"; then \
2568	      $(UPDATE_DESKTOP_DATABASE) -q $(DESKTOPPATH); \
2569	   fi \
2570	fi
2571
2572$(HELPSOURCE)/vim.1 $(MACROSOURCE) $(TOOLSSOURCE):
2573	@echo Runtime files not found.
2574	@echo You need to unpack the runtime archive before running "make install".
2575	test -f error
2576
2577$(DESTDIR)$(exec_prefix) $(DEST_BIN) \
2578		$(DEST_VIM) $(DEST_RT) $(DEST_HELP) \
2579		$(DEST_PRINT) $(DEST_COL) $(DEST_SYN) $(DEST_IND) $(DEST_FTP) \
2580		$(DEST_LANG) $(DEST_KMAP) $(DEST_COMP) $(DEST_MACRO) \
2581		$(DEST_PACK) $(DEST_TOOLS) $(DEST_TUTOR) $(DEST_SPELL) \
2582		$(DEST_AUTO) $(DEST_AUTO)/xml $(DEST_PLUG):
2583	-$(SHELL) ./mkinstalldirs $@
2584	-chmod $(DIRMOD) $@
2585
2586# create links from various names to vim.  This is only done when the links
2587# (or executables with the same name) don't exist yet.
2588installlinks: $(GUI_TARGETS) \
2589			$(DEST_BIN)/$(EXTARGET) \
2590			$(DEST_BIN)/$(VIEWTARGET) \
2591			$(DEST_BIN)/$(RVIMTARGET) \
2592			$(DEST_BIN)/$(RVIEWTARGET) \
2593			$(INSTALLVIMDIFF)
2594
2595installglinks: $(DEST_BIN)/$(GVIMTARGET) \
2596			$(DEST_BIN)/$(GVIEWTARGET) \
2597			$(DEST_BIN)/$(RGVIMTARGET) \
2598			$(DEST_BIN)/$(RGVIEWTARGET) \
2599			$(DEST_BIN)/$(EVIMTARGET) \
2600			$(DEST_BIN)/$(EVIEWTARGET) \
2601			$(INSTALLGVIMDIFF)
2602
2603installvimdiff: $(DEST_BIN)/$(VIMDIFFTARGET)
2604installgvimdiff: $(DEST_BIN)/$(GVIMDIFFTARGET)
2605
2606$(DEST_BIN)/$(EXTARGET):
2607	cd $(DEST_BIN); ln -s $(VIMTARGET) $(EXTARGET)
2608
2609$(DEST_BIN)/$(VIEWTARGET):
2610	cd $(DEST_BIN); ln -s $(VIMTARGET) $(VIEWTARGET)
2611
2612$(DEST_BIN)/$(GVIMTARGET):
2613	cd $(DEST_BIN); ln -s $(VIMTARGET) $(GVIMTARGET)
2614
2615$(DEST_BIN)/$(GVIEWTARGET):
2616	cd $(DEST_BIN); ln -s $(VIMTARGET) $(GVIEWTARGET)
2617
2618$(DEST_BIN)/$(RVIMTARGET):
2619	cd $(DEST_BIN); ln -s $(VIMTARGET) $(RVIMTARGET)
2620
2621$(DEST_BIN)/$(RVIEWTARGET):
2622	cd $(DEST_BIN); ln -s $(VIMTARGET) $(RVIEWTARGET)
2623
2624$(DEST_BIN)/$(RGVIMTARGET):
2625	cd $(DEST_BIN); ln -s $(VIMTARGET) $(RGVIMTARGET)
2626
2627$(DEST_BIN)/$(RGVIEWTARGET):
2628	cd $(DEST_BIN); ln -s $(VIMTARGET) $(RGVIEWTARGET)
2629
2630$(DEST_BIN)/$(VIMDIFFTARGET):
2631	cd $(DEST_BIN); ln -s $(VIMTARGET) $(VIMDIFFTARGET)
2632
2633$(DEST_BIN)/$(GVIMDIFFTARGET):
2634	cd $(DEST_BIN); ln -s $(VIMTARGET) $(GVIMDIFFTARGET)
2635
2636$(DEST_BIN)/$(EVIMTARGET):
2637	cd $(DEST_BIN); ln -s $(VIMTARGET) $(EVIMTARGET)
2638
2639$(DEST_BIN)/$(EVIEWTARGET):
2640	cd $(DEST_BIN); ln -s $(VIMTARGET) $(EVIEWTARGET)
2641
2642# Create links for the manual pages with various names to vim.	This is only
2643# done when the links (or manpages with the same name) don't exist yet.
2644
2645INSTALLMLARGS = $(VIMNAME) $(VIMDIFFNAME) $(EVIMNAME) \
2646		$(EXNAME) $(VIEWNAME) $(RVIMNAME) $(RVIEWNAME) \
2647		$(GVIMNAME) $(GVIEWNAME) $(RGVIMNAME) $(RGVIEWNAME) \
2648		$(GVIMDIFFNAME) $(EVIEWNAME)
2649
2650installmanlinks:
2651	-$(SHELL) ./installml.sh install "$(GUI_MAN_TARGETS)" \
2652		$(DEST_MAN) $(INSTALLMLARGS)
2653
2654uninstall: uninstall_runtime
2655	-rm -f $(DEST_BIN)/$(VIMTARGET)
2656	-rm -f $(DEST_BIN)/vimtutor
2657	-rm -f $(DEST_BIN)/gvimtutor
2658	-rm -f $(DEST_BIN)/$(EXTARGET) $(DEST_BIN)/$(VIEWTARGET)
2659	-rm -f $(DEST_BIN)/$(GVIMTARGET) $(DEST_BIN)/$(GVIEWTARGET)
2660	-rm -f $(DEST_BIN)/$(RVIMTARGET) $(DEST_BIN)/$(RVIEWTARGET)
2661	-rm -f $(DEST_BIN)/$(RGVIMTARGET) $(DEST_BIN)/$(RGVIEWTARGET)
2662	-rm -f $(DEST_BIN)/$(VIMDIFFTARGET) $(DEST_BIN)/$(GVIMDIFFTARGET)
2663	-rm -f $(DEST_BIN)/$(EVIMTARGET) $(DEST_BIN)/$(EVIEWTARGET)
2664	-rm -f $(DEST_BIN)/xxd$(EXEEXT)
2665
2666# Note: the "rmdir" will fail if any files were added after "make install"
2667uninstall_runtime:
2668	-$(SHELL) ./installman.sh uninstall $(DEST_MAN) "" $(INSTALLMANARGS)
2669	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_FR) "" $(INSTALLMANARGS)
2670	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_FR_I) "" $(INSTALLMANARGS)
2671	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_FR_U) "" $(INSTALLMANARGS)
2672	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_IT) "" $(INSTALLMANARGS)
2673	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_IT_I) "" $(INSTALLMANARGS)
2674	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_IT_U) "" $(INSTALLMANARGS)
2675	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_JA_U) "" $(INSTALLMANARGS)
2676	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_PL) "" $(INSTALLMANARGS)
2677	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_PL_I) "" $(INSTALLMANARGS)
2678	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_PL_U) "" $(INSTALLMANARGS)
2679	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_RU) "" $(INSTALLMANARGS)
2680	-$(SHELL) ./installman.sh uninstall $(DEST_MAN_RU_U) "" $(INSTALLMANARGS)
2681	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2682		$(DEST_MAN) $(INSTALLMLARGS)
2683	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2684		$(DEST_MAN_FR) $(INSTALLMLARGS)
2685	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2686		$(DEST_MAN_FR_I) $(INSTALLMLARGS)
2687	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2688		$(DEST_MAN_FR_U) $(INSTALLMLARGS)
2689	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2690		$(DEST_MAN_IT) $(INSTALLMLARGS)
2691	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2692		$(DEST_MAN_IT_I) $(INSTALLMLARGS)
2693	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2694		$(DEST_MAN_IT_U) $(INSTALLMLARGS)
2695	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2696		$(DEST_MAN_JA_U) $(INSTALLMLARGS)
2697	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2698		$(DEST_MAN_PL) $(INSTALLMLARGS)
2699	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2700		$(DEST_MAN_PL_I) $(INSTALLMLARGS)
2701	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2702		$(DEST_MAN_PL_U) $(INSTALLMLARGS)
2703	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2704		$(DEST_MAN_RU) $(INSTALLMLARGS)
2705	-$(SHELL) ./installml.sh uninstall "$(GUI_MAN_TARGETS)" \
2706		$(DEST_MAN_RU_U) $(INSTALLMLARGS)
2707	-rm -f $(DEST_MAN)/xxd.1
2708	-rm -f $(DEST_MAN_FR)/xxd.1 $(DEST_MAN_FR_I)/xxd.1 $(DEST_MAN_FR_U)/xxd.1
2709	-rm -f $(DEST_MAN_IT)/xxd.1 $(DEST_MAN_IT_I)/xxd.1 $(DEST_MAN_IT_U)/xxd.1
2710	-rm -f $(DEST_MAN_JA_U)/xxd.1
2711	-rm -f $(DEST_MAN_PL)/xxd.1 $(DEST_MAN_PL_I)/xxd.1 $(DEST_MAN_PL_U)/xxd.1
2712	-rm -f $(DEST_MAN_RU)/xxd.1 $(DEST_MAN_RU_U)/xxd.1
2713	-rm -f $(DEST_HELP)/*.txt $(DEST_HELP)/tags $(DEST_HELP)/*.pl
2714	-rm -f $(DEST_HELP)/*.??x $(DEST_HELP)/tags-??
2715	-rm -f $(SYS_RGB_FILE)
2716	-rm -f $(SYS_MENU_FILE) $(SYS_SYNMENU_FILE) $(SYS_DELMENU_FILE)
2717	-rm -f $(SYS_BUGR_FILE) $(VIM_DEFAULTS_FILE) $(EVIM_FILE) $(MSWIN_FILE)
2718	-rm -f $(DEST_SCRIPT)/gvimrc_example.vim $(DEST_SCRIPT)/vimrc_example.vim
2719	-rm -f $(SYS_FILETYPE_FILE) $(SYS_FTOFF_FILE) $(SYS_SCRIPTS_FILE)
2720	-rm -f $(SYS_INDOFF_FILE) $(SYS_INDENT_FILE)
2721	-rm -f $(SYS_FTPLUGOF_FILE) $(SYS_FTPLUGIN_FILE)
2722	-rm -f $(SYS_OPTWIN_FILE)
2723	-rm -f $(DEST_COL)/*.vim $(DEST_COL)/README.txt
2724	-rm -f $(DEST_SYN)/*.vim $(DEST_SYN)/README.txt
2725	-rm -f $(DEST_IND)/*.vim $(DEST_IND)/README.txt
2726	-rm -rf $(DEST_MACRO)
2727	-rm -rf $(DEST_PACK)
2728	-rm -rf $(DEST_TUTOR)
2729	-rm -rf $(DEST_SPELL)
2730	-rm -rf $(DEST_TOOLS)
2731	-rm -rf $(DEST_LANG)
2732	-rm -rf $(DEST_KMAP)
2733	-rm -rf $(DEST_COMP)
2734	-rm -f $(DEST_PRINT)/*.ps
2735	-rmdir $(DEST_HELP) $(DEST_PRINT) $(DEST_COL) $(DEST_SYN) $(DEST_IND)
2736	-rm -rf $(DEST_FTP)/*.vim $(DEST_FTP)/README.txt $(DEST_FTP)/logtalk.dict
2737	-rm -f $(DEST_AUTO)/*.vim $(DEST_AUTO)/README.txt $(DEST_AUTO)/xml/*.vim
2738	-rm -f $(DEST_PLUG)/*.vim $(DEST_PLUG)/README.txt
2739	-rmdir $(DEST_FTP) $(DEST_AUTO)/xml $(DEST_AUTO) $(DEST_PLUG) $(DEST_RT)
2740#	This will fail when other Vim versions are installed, no worries.
2741	-rmdir $(DEST_VIM)
2742
2743# Clean up all the files that have been produced, except configure's.
2744# We support common typing mistakes for Juergen! :-)
2745clean celan: testclean
2746	-rm -f *.o objects/* core $(VIMTARGET).core $(VIMTARGET) vim xxd/*.o
2747	-rm -f $(TOOLS) auto/osdef.h auto/pathdef.c auto/if_perl.c auto/gui_gtk_gresources.c auto/gui_gtk_gresources.h
2748	-rm -f conftest* *~ auto/link.sed
2749	-rm -f $(UNITTEST_TARGETS)
2750	-rm -f runtime pixmaps
2751	-rm -rf $(APPDIR)
2752	-rm -rf mzscheme_base.c
2753	if test -d $(PODIR); then \
2754		cd $(PODIR); $(MAKE) prefix=$(DESTDIR)$(prefix) clean; \
2755	fi
2756
2757# Make a shadow directory for compilation on another system or with different
2758# features.
2759SHADOWDIR = shadow
2760
2761shadow:	runtime pixmaps
2762	mkdir $(SHADOWDIR)
2763	cd $(SHADOWDIR); ln -s ../*.[ch] ../*.in ../*.sh ../*.xs ../*.xbm ../gui_gtk_res.xml ../toolcheck ../proto ../vimtutor ../gvimtutor ../mkinstalldirs .
2764	mkdir $(SHADOWDIR)/auto
2765	cd $(SHADOWDIR)/auto; ln -s ../../auto/configure .
2766	mkdir $(SHADOWDIR)/po
2767	cd $(SHADOWDIR)/po; ln -s ../../po/*.po ../../po/*.mak ../../po/*.vim ../../po/Makefile .
2768	cd $(SHADOWDIR); rm -f auto/link.sed
2769	cp Makefile configure $(SHADOWDIR)
2770	rm -f $(SHADOWDIR)/auto/config.mk $(SHADOWDIR)/config.mk.dist
2771	cp config.mk.dist $(SHADOWDIR)/auto/config.mk
2772	cp config.mk.dist $(SHADOWDIR)
2773	mkdir $(SHADOWDIR)/xxd
2774	cd $(SHADOWDIR)/xxd; ln -s ../../xxd/*.[ch] ../../xxd/Make* .
2775	if test -d $(RSRC_DIR); then \
2776		cd $(SHADOWDIR); \
2777		ln -s ../infplist.xml .; \
2778		ln -s ../$(RSRC_DIR) ../os_mac.rsr.hqx ../dehqx.py .; \
2779	fi
2780	mkdir $(SHADOWDIR)/testdir
2781	cd $(SHADOWDIR)/testdir; ln -s ../../testdir/Makefile \
2782				 ../../testdir/Make_all.mak \
2783				 ../../testdir/README.txt \
2784				 ../../testdir/*.in \
2785				 ../../testdir/*.vim \
2786				 ../../testdir/*.py \
2787				 ../../testdir/python* \
2788				 ../../testdir/pyxfile \
2789				 ../../testdir/sautest \
2790				 ../../testdir/samples \
2791				 ../../testdir/test83-tags? \
2792				 ../../testdir/*.ok .
2793
2794# Link needed for doing "make install" in a shadow directory.
2795runtime:
2796	-ln -s ../runtime .
2797
2798# Link needed for doing "make" using GTK in a shadow directory.
2799pixmaps:
2800	-ln -s ../pixmaps .
2801
2802# Update the synmenu.vim file with the latest Syntax menu.
2803# This is only needed when runtime/makemenu.vim was changed.
2804menu: ./vim ../runtime/makemenu.vim
2805	./vim -u ../runtime/makemenu.vim
2806
2807# Start configure from scratch
2808scrub scratch:
2809	-rm -f auto/config.status auto/config.cache config.log auto/config.log
2810	-rm -f auto/config.h auto/link.log auto/link.sed auto/config.mk
2811	touch auto/config.h
2812	cp config.mk.dist auto/config.mk
2813
2814distclean: clean scratch
2815	-rm -f tags
2816
2817dist: distclean
2818	@echo
2819	@echo Making the distribution has to be done in the top directory
2820
2821mdepend:
2822	-@rm -f Makefile~
2823	cp Makefile Makefile~
2824	sed -e '/\#\#\# Dependencies/q' < Makefile > tmp_make
2825	@for i in $(ALL_SRC) ; do \
2826	  echo "$$i" ; \
2827	  echo `echo "$$i" | sed -e 's/[^ ]*\.c$$/objects\/\1.o/'`": $$i" `\
2828	    $(CPP) $$i |\
2829	    grep '^# .*"\./.*\.h"' |\
2830	    sort -t'"' -u +1 -2 |\
2831	    sed -e 's/.*"\.\/\(.*\)".*/\1/'\
2832	    ` >> tmp_make ; \
2833	done
2834	mv tmp_make Makefile
2835
2836depend:
2837	-@rm -f Makefile~
2838	cp Makefile Makefile~
2839	sed -e '/\#\#\# Dependencies/q' < Makefile > tmp_make
2840	-for i in $(ALL_SRC); do echo $$i; \
2841		$(CPP_DEPEND) $$i | \
2842		sed -e 's+^\([^ ]*\.o\)+objects/\1+' >> tmp_make; done
2843	mv tmp_make Makefile
2844
2845# Run lint.  Clean up the *.ln files that are sometimes left behind.
2846lint:
2847	$(LINT) $(LINT_OPTIONS) $(LINT_CFLAGS) $(LINT_EXTRA) $(LINT_SRC)
2848	-rm -f *.ln
2849
2850# Check dosinst.c with lint.
2851lintinstall:
2852	$(LINT) $(LINT_OPTIONS) -DWIN32 -DUNIX_LINT dosinst.c
2853	-rm -f dosinst.ln
2854
2855###########################################################################
2856
2857.c.o:
2858	$(CCC) $<
2859
2860auto/if_perl.c: if_perl.xs
2861	$(PERL) -e 'unless ( $$] >= 5.005 ) { for (qw(na defgv errgv)) { print "#define PL_$$_ $$_\n" }}' > $@
2862	$(PERL) $(PERL_XSUBPP) -prototypes -typemap \
2863	    $(PERLLIB)/ExtUtils/typemap if_perl.xs >> $@
2864
2865auto/osdef.h: auto/config.h osdef.sh osdef1.h.in osdef2.h.in
2866	CC="$(CC) $(OSDEF_CFLAGS)" srcdir=$(srcdir) sh $(srcdir)/osdef.sh
2867
2868auto/pathdef.c: Makefile auto/config.mk
2869	-@echo creating $@
2870	-@echo '/* pathdef.c */' > $@
2871	-@echo '/* This file is automatically created by Makefile' >> $@
2872	-@echo ' * DO NOT EDIT!  Change Makefile only. */' >> $@
2873	-@echo '#include "vim.h"' >> $@
2874	-@echo 'char_u *default_vim_dir = (char_u *)"$(VIMRCLOC)";' | $(QUOTESED) >> $@
2875	-@echo 'char_u *default_vimruntime_dir = (char_u *)"$(VIMRUNTIMEDIR)";' | $(QUOTESED) >> $@
2876	-@echo 'char_u *all_cflags = (char_u *)"$(CC) -c -I$(srcdir) $(ALL_CFLAGS)";' | $(QUOTESED) >>  $@
2877	-@echo 'char_u *all_lflags = (char_u *)"$(CC) $(ALL_LIB_DIRS) $(LDFLAGS) -o $(VIMTARGET) $(ALL_LIBS) ";' | $(QUOTESED) >>  $@
2878	-@echo 'char_u *compiled_user = (char_u *)"' | tr -d $(NL) >> $@
2879	-@if test -n "$(COMPILEDBY)"; then \
2880		echo "$(COMPILEDBY)" | tr -d $(NL) >> $@; \
2881		else ((logname) 2>/dev/null || whoami) | tr -d $(NL) >> $@; fi
2882	-@echo '";' >> $@
2883	-@echo 'char_u *compiled_sys = (char_u *)"' | tr -d $(NL) >> $@
2884	-@if test -z "$(COMPILEDBY)"; then hostname | tr -d $(NL) >> $@; fi
2885	-@echo '";' >> $@
2886	-@sh $(srcdir)/pathdef.sh
2887
2888GUI_GTK_RES_INPUTS = \
2889	../pixmaps/stock_vim_build_tags.png \
2890	../pixmaps/stock_vim_find_help.png \
2891	../pixmaps/stock_vim_save_all.png \
2892	../pixmaps/stock_vim_session_load.png \
2893	../pixmaps/stock_vim_session_new.png \
2894	../pixmaps/stock_vim_session_save.png \
2895	../pixmaps/stock_vim_shell.png \
2896	../pixmaps/stock_vim_window_maximize.png \
2897	../pixmaps/stock_vim_window_maximize_width.png \
2898	../pixmaps/stock_vim_window_minimize.png \
2899	../pixmaps/stock_vim_window_minimize_width.png \
2900	../pixmaps/stock_vim_window_split.png \
2901	../pixmaps/stock_vim_window_split_vertical.png
2902
2903auto/gui_gtk_gresources.c: gui_gtk_res.xml $(GUI_GTK_RES_INPUTS)
2904	$(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=../pixmaps --generate --c-name=gui_gtk --manual-register gui_gtk_res.xml
2905auto/gui_gtk_gresources.h: gui_gtk_res.xml $(GUI_GTK_RES_INPUTS)
2906	if test -z "$(GLIB_COMPILE_RESOURCES)"; then touch $@; else \
2907		$(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=../pixmaps --generate --c-name=gui_gtk --manual-register gui_gtk_res.xml; \
2908	fi
2909
2910# All the object files are put in the "objects" directory.  Since not all make
2911# commands understand putting object files in another directory, it must be
2912# specified for each file separately.
2913
2914objects: objects/.dirstamp
2915
2916objects/.dirstamp:
2917	mkdir -p objects
2918	touch objects/.dirstamp
2919
2920# All object files depend on the objects directory, so that parallel make
2921# works.  Can't depend on the directory itself, its timestamp changes all the
2922# time.
2923$(ALL_OBJ): objects/.dirstamp
2924
2925objects/arabic.o: arabic.c
2926	$(CCC) -o $@ arabic.c
2927
2928objects/blowfish.o: blowfish.c
2929	$(CCC) -o $@ blowfish.c
2930
2931objects/buffer.o: buffer.c
2932	$(CCC) -o $@ buffer.c
2933
2934objects/charset.o: charset.c
2935	$(CCC) -o $@ charset.c
2936
2937objects/crypt.o: crypt.c
2938	$(CCC) -o $@ crypt.c
2939
2940objects/crypt_zip.o: crypt_zip.c
2941	$(CCC) -o $@ crypt_zip.c
2942
2943objects/dict.o: dict.c
2944	$(CCC) -o $@ dict.c
2945
2946objects/diff.o: diff.c
2947	$(CCC) -o $@ diff.c
2948
2949objects/digraph.o: digraph.c
2950	$(CCC) -o $@ digraph.c
2951
2952objects/edit.o: edit.c
2953	$(CCC) -o $@ edit.c
2954
2955objects/eval.o: eval.c
2956	$(CCC) -o $@ eval.c
2957
2958objects/evalfunc.o: evalfunc.c
2959	$(CCC) -o $@ evalfunc.c
2960
2961objects/ex_cmds.o: ex_cmds.c
2962	$(CCC) -o $@ ex_cmds.c
2963
2964objects/ex_cmds2.o: ex_cmds2.c
2965	$(CCC) -o $@ ex_cmds2.c
2966
2967objects/ex_docmd.o: ex_docmd.c
2968	$(CCC) -o $@ ex_docmd.c
2969
2970objects/ex_eval.o: ex_eval.c
2971	$(CCC) -o $@ ex_eval.c
2972
2973objects/ex_getln.o: ex_getln.c
2974	$(CCC) -o $@ ex_getln.c
2975
2976objects/farsi.o: farsi.c
2977	$(CCC) -o $@ farsi.c
2978
2979objects/fileio.o: fileio.c
2980	$(CCC) -o $@ fileio.c
2981
2982objects/fold.o: fold.c
2983	$(CCC) -o $@ fold.c
2984
2985objects/getchar.o: getchar.c
2986	$(CCC) -o $@ getchar.c
2987
2988objects/hardcopy.o: hardcopy.c
2989	$(CCC) -o $@ hardcopy.c
2990
2991objects/hashtab.o: hashtab.c
2992	$(CCC) -o $@ hashtab.c
2993
2994objects/gui.o: gui.c
2995	$(CCC) -o $@ gui.c
2996
2997objects/gui_at_fs.o: gui_at_fs.c
2998	$(CCC) -o $@ gui_at_fs.c
2999
3000objects/gui_at_sb.o: gui_at_sb.c
3001	$(CCC) -o $@ gui_at_sb.c
3002
3003objects/gui_athena.o: gui_athena.c
3004	$(CCC) -o $@ gui_athena.c
3005
3006objects/gui_beval.o: gui_beval.c
3007	$(CCC) -o $@ gui_beval.c
3008
3009objects/gui_gtk.o: gui_gtk.c
3010	$(CCC) -o $@ gui_gtk.c
3011
3012objects/gui_gtk_f.o: gui_gtk_f.c
3013	$(CCC) -o $@ gui_gtk_f.c
3014
3015objects/gui_gtk_gresources.o: auto/gui_gtk_gresources.c
3016	$(CCC_NF) $(PERL_CFLAGS) $(ALL_CFLAGS) -o $@ auto/gui_gtk_gresources.c
3017
3018objects/gui_gtk_x11.o: gui_gtk_x11.c
3019	$(CCC) -o $@ gui_gtk_x11.c
3020
3021objects/gui_motif.o: gui_motif.c
3022	$(CCC) -o $@ gui_motif.c
3023
3024objects/gui_xmdlg.o: gui_xmdlg.c
3025	$(CCC) -o $@ gui_xmdlg.c
3026
3027objects/gui_xmebw.o: gui_xmebw.c
3028	$(CCC) -o $@ gui_xmebw.c
3029
3030objects/gui_x11.o: gui_x11.c
3031	$(CCC) -o $@ gui_x11.c
3032
3033objects/gui_photon.o: gui_photon.c
3034	$(CCC) -o $@ gui_photon.c
3035
3036objects/gui_mac.o: gui_mac.c
3037	$(CCC) -o $@ gui_mac.c
3038
3039objects/hangulin.o: hangulin.c
3040	$(CCC) -o $@ hangulin.c
3041
3042objects/if_cscope.o: if_cscope.c
3043	$(CCC) -o $@ if_cscope.c
3044
3045objects/if_xcmdsrv.o: if_xcmdsrv.c
3046	$(CCC) -o $@ if_xcmdsrv.c
3047
3048objects/if_lua.o: if_lua.c
3049	$(CCC_NF) $(LUA_CFLAGS) $(ALL_CFLAGS) -o $@ if_lua.c
3050
3051objects/if_mzsch.o: if_mzsch.c $(MZSCHEME_EXTRA)
3052	$(CCC) -o $@ $(MZSCHEME_CFLAGS_EXTRA) if_mzsch.c
3053
3054mzscheme_base.c:
3055	$(MZSCHEME_MZC) --c-mods mzscheme_base.c ++lib scheme/base
3056
3057objects/if_perl.o: auto/if_perl.c
3058	$(CCC_NF) $(PERL_CFLAGS) $(ALL_CFLAGS) -o $@ auto/if_perl.c
3059
3060objects/if_perlsfio.o: if_perlsfio.c
3061	$(CCC_NF) $(PERL_CFLAGS) $(ALL_CFLAGS) -o $@ if_perlsfio.c
3062
3063objects/py_getpath.o: $(PYTHON_CONFDIR)/getpath.c
3064	$(CCC_NF) $(PYTHON_CFLAGS) $(ALL_CFLAGS) -o $@ \
3065		$(PYTHON_CONFDIR)/getpath.c \
3066		-I$(PYTHON_CONFDIR) -DHAVE_CONFIG_H -DNO_MAIN \
3067		$(PYTHON_GETPATH_CFLAGS)
3068
3069objects/if_python.o: if_python.c if_py_both.h
3070	$(CCC_NF) $(PYTHON_CFLAGS) $(PYTHON_CFLAGS_EXTRA) $(ALL_CFLAGS) -o $@ if_python.c
3071
3072objects/if_python3.o: if_python3.c if_py_both.h
3073	$(CCC_NF) $(PYTHON3_CFLAGS) $(PYTHON3_CFLAGS_EXTRA) $(ALL_CFLAGS) -o $@ if_python3.c
3074
3075objects/if_ruby.o: if_ruby.c
3076	$(CCC_NF) $(RUBY_CFLAGS) $(ALL_CFLAGS) -o $@ if_ruby.c
3077
3078objects/if_tcl.o: if_tcl.c
3079	$(CCC_NF) $(TCL_CFLAGS) $(ALL_CFLAGS) -o $@ if_tcl.c
3080
3081objects/integration.o: integration.c
3082	$(CCC) -o $@ integration.c
3083
3084objects/json.o: json.c
3085	$(CCC) -o $@ json.c
3086
3087objects/json_test.o: json_test.c
3088	$(CCC) -o $@ json_test.c
3089
3090objects/kword_test.o: kword_test.c
3091	$(CCC) -o $@ kword_test.c
3092
3093objects/list.o: list.c
3094	$(CCC) -o $@ list.c
3095
3096objects/main.o: main.c
3097	$(CCC) -o $@ main.c
3098
3099objects/mark.o: mark.c
3100	$(CCC) -o $@ mark.c
3101
3102objects/memfile.o: memfile.c
3103	$(CCC) -o $@ memfile.c
3104
3105objects/memfile_test.o: memfile_test.c
3106	$(CCC) -o $@ memfile_test.c
3107
3108objects/memline.o: memline.c
3109	$(CCC) -o $@ memline.c
3110
3111objects/menu.o: menu.c
3112	$(CCC) -o $@ menu.c
3113
3114objects/message.o: message.c
3115	$(CCC) -o $@ message.c
3116
3117objects/message_test.o: message_test.c
3118	$(CCC) -o $@ message_test.c
3119
3120objects/misc1.o: misc1.c
3121	$(CCC) -o $@ misc1.c
3122
3123objects/misc2.o: misc2.c
3124	$(CCC) -o $@ misc2.c
3125
3126objects/move.o: move.c
3127	$(CCC) -o $@ move.c
3128
3129objects/mbyte.o: mbyte.c
3130	$(CCC) -o $@ mbyte.c
3131
3132objects/normal.o: normal.c
3133	$(CCC) -o $@ normal.c
3134
3135objects/ops.o: ops.c
3136	$(CCC) -o $@ ops.c
3137
3138objects/option.o: option.c
3139	$(CCC_NF) $(LUA_CFLAGS) $(PERL_CFLAGS) $(PYTHON_CFLAGS) $(PYTHON3_CFLAGS) $(RUBY_CFLAGS) $(TCL_CFLAGS) $(ALL_CFLAGS) -o $@ option.c
3140
3141objects/os_beos.o: os_beos.c
3142	$(CCC) -o $@ os_beos.c
3143
3144objects/os_qnx.o: os_qnx.c
3145	$(CCC) -o $@ os_qnx.c
3146
3147objects/os_macosx.o: os_macosx.m
3148	$(CCC) -o $@ os_macosx.m
3149
3150objects/os_mac_conv.o: os_mac_conv.c
3151	$(CCC) -o $@ os_mac_conv.c
3152
3153objects/os_unix.o: os_unix.c
3154	$(CCC) -o $@ os_unix.c
3155
3156objects/os_mswin.o: os_mswin.c
3157	$(CCC) -o $@ os_mswin.c
3158
3159objects/winclip.o: winclip.c
3160	$(CCC) -o $@ winclip.c
3161
3162objects/pathdef.o: auto/pathdef.c
3163	$(CCC) -o $@ auto/pathdef.c
3164
3165objects/pty.o: pty.c
3166	$(CCC) -o $@ pty.c
3167
3168objects/popupmnu.o: popupmnu.c
3169	$(CCC) -o $@ popupmnu.c
3170
3171objects/quickfix.o: quickfix.c
3172	$(CCC) -o $@ quickfix.c
3173
3174objects/regexp.o: regexp.c regexp_nfa.c
3175	$(CCC) -o $@ regexp.c
3176
3177objects/screen.o: screen.c
3178	$(CCC) -o $@ screen.c
3179
3180objects/search.o: search.c
3181	$(CCC) -o $@ search.c
3182
3183objects/sha256.o: sha256.c
3184	$(CCC) -o $@ sha256.c
3185
3186objects/spell.o: spell.c
3187	$(CCC) -o $@ spell.c
3188
3189objects/spellfile.o: spellfile.c
3190	$(CCC) -o $@ spellfile.c
3191
3192objects/syntax.o: syntax.c
3193	$(CCC) -o $@ syntax.c
3194
3195objects/tag.o: tag.c
3196	$(CCC) -o $@ tag.c
3197
3198objects/term.o: term.c
3199	$(CCC) -o $@ term.c
3200
3201objects/ui.o: ui.c
3202	$(CCC) -o $@ ui.c
3203
3204objects/undo.o: undo.c
3205	$(CCC) -o $@ undo.c
3206
3207objects/userfunc.o: userfunc.c
3208	$(CCC) -o $@ userfunc.c
3209
3210objects/window.o: window.c
3211	$(CCC) -o $@ window.c
3212
3213objects/workshop.o: workshop.c
3214	$(CCC) -o $@ workshop.c
3215
3216objects/wsdebug.o: wsdebug.c
3217	$(CCC) -o $@ wsdebug.c
3218
3219objects/netbeans.o: netbeans.c
3220	$(CCC) -o $@ netbeans.c
3221
3222objects/channel.o: channel.c
3223	$(CCC) -o $@ channel.c
3224
3225Makefile:
3226	@echo The name of the makefile MUST be "Makefile" (with capital M)!!!!
3227
3228###############################################################################
3229### MacOS X installation
3230###
3231### This installs a runnable Vim.app in $(prefix)
3232
3233REZ    = /Developer/Tools/Rez
3234RESDIR = $(APPDIR)/Contents/Resources
3235VERSION = $(VIMMAJOR).$(VIMMINOR)
3236
3237### Common flags
3238M4FLAGSX = $(M4FLAGS) -DAPP_EXE=$(VIMNAME) -DAPP_NAME=$(VIMNAME) \
3239		-DAPP_VER=$(VERSION)
3240
3241install_macosx: gui_bundle
3242# Remove the link to the runtime dir, don't want to copy all of that.
3243	-rm $(RESDIR)/vim/runtime
3244	$(INSTALL_DATA_R) $(APPDIR) $(DESTDIR)$(prefix)
3245# Generate the help tags file now, it won't work with "make installruntime".
3246	-@srcdir=`pwd`; cd $(HELPSOURCE); $(MAKE) VIMEXE=$$srcdir/$(VIMTARGET) vimtags
3247# Install the runtime files.  Recursive!
3248	-mkdir -p $(DESTDIR)$(prefix)/$(RESDIR)/vim/runtime
3249#	-mkdir $(DESTDIR)$(prefix)/$(APPDIR)/bin
3250	srcdir=`pwd`; $(MAKE) -f Makefile installruntime \
3251		VIMEXE=$$srcdir/$(VIMTARGET) \
3252		prefix=$(DESTDIR)$(prefix)/$(RESDIR)$(VIMDIR) \
3253		exec_prefix=$(DESTDIR)$(prefix)/$(APPDIR)/Contents \
3254		BINDIR=$(DESTDIR)$(prefix)/$(APPDIR)/Contents/MacOS \
3255		VIMLOC=$(DESTDIR)$(prefix)/$(RESDIR)$(VIMDIR) \
3256		VIMRTLOC=$(DESTDIR)$(prefix)/$(RESDIR)$(VIMDIR)/runtime
3257# Put the link back.
3258	ln -s `pwd`/../runtime $(RESDIR)/vim
3259# Copy rgb.txt, Mac doesn't always have X11
3260	$(INSTALL_DATA) $(SCRIPTSOURCE)/rgb.txt $(DESTDIR)$(prefix)/$(RESDIR)/vim/runtime
3261# TODO: Create the vimtutor and/or gvimtutor application.
3262
3263gui_bundle: $(RESDIR) bundle-dir bundle-executable bundle-info bundle-resource \
3264	bundle-language
3265
3266$(RESDIR):
3267	mkdir -p $@
3268
3269bundle-dir: $(APPDIR)/Contents $(VIMTARGET)
3270# Make a link to the runtime directory, so that we can try out the executable
3271# without installing it.
3272	mkdir -p $(RESDIR)/vim
3273	-ln -s `pwd`/../runtime $(RESDIR)/vim
3274
3275bundle-executable: $(VIMTARGET)
3276	mkdir -p $(APPDIR)/Contents/MacOS
3277	cp $(VIMTARGET) $(APPDIR)/Contents/MacOS/$(VIMTARGET)
3278
3279bundle-info:  bundle-dir
3280	@echo "Creating PkgInfo"
3281	@echo -n "APPLVIM!" > $(APPDIR)/Contents/PkgInfo
3282	@echo "Creating Info.plist"
3283	m4 $(M4FLAGSX) infplist.xml > $(APPDIR)/Contents/Info.plist
3284
3285bundle-resource: bundle-dir bundle-rsrc
3286	cp -f $(RSRC_DIR)/*.icns $(RESDIR)
3287
3288### Classic resources
3289# Resource fork (in the form of a .rsrc file) for Classic Vim (Mac OS 9)
3290# This file is also required for OS X Vim.
3291bundle-rsrc: os_mac.rsr.hqx
3292	@echo "Creating resource fork"
3293	python dehqx.py $<
3294	rm -f gui_mac.rsrc
3295	mv gui_mac.rsrc.rsrcfork $(RESDIR)/$(VIMNAME).rsrc
3296
3297# po/Make_osx.pl says something about generating a Mac message file
3298# for Ukrainian.  Would somebody using Mac OS X in Ukrainian
3299# *really* be upset that Carbon Vim was not localised in
3300# Ukrainian?
3301#
3302#bundle-language: bundle-dir po/Make_osx.pl
3303#	cd po && perl Make_osx.pl --outdir ../$(RESDIR) $(MULTILANG)
3304bundle-language: bundle-dir
3305
3306$(APPDIR)/Contents:
3307	-$(SHELL) ./mkinstalldirs $(APPDIR)/Contents/MacOS
3308	-$(SHELL) ./mkinstalldirs $(RESDIR)/English.lproj
3309
3310
3311###############################################################################
3312### (automatically generated by 'make depend')
3313### Dependencies:
3314objects/arabic.o: arabic.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3315 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3316 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3317 globals.h farsi.h arabic.h
3318objects/blowfish.o: blowfish.c vim.h auto/config.h feature.h os_unix.h \
3319 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3320 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3321 proto.h globals.h farsi.h arabic.h
3322objects/buffer.o: buffer.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3323 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3324 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3325 globals.h farsi.h arabic.h version.h
3326objects/charset.o: charset.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3327 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3328 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3329 globals.h farsi.h arabic.h
3330objects/crypt.o: crypt.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3331 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3332 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3333 globals.h farsi.h arabic.h
3334objects/crypt_zip.o: crypt_zip.c vim.h auto/config.h feature.h os_unix.h \
3335 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3336 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3337 proto.h globals.h farsi.h arabic.h
3338objects/dict.o: dict.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3339 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3340 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3341 globals.h farsi.h arabic.h
3342objects/diff.o: diff.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3343 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3344 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3345 globals.h farsi.h arabic.h
3346objects/digraph.o: digraph.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3347 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3348 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3349 globals.h farsi.h arabic.h
3350objects/edit.o: edit.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3351 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3352 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3353 globals.h farsi.h arabic.h
3354objects/eval.o: eval.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3355 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3356 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3357 globals.h farsi.h arabic.h version.h
3358objects/evalfunc.o: evalfunc.c vim.h auto/config.h feature.h os_unix.h \
3359 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3360 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3361 proto.h globals.h farsi.h arabic.h version.h
3362objects/ex_cmds.o: ex_cmds.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3363 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3364 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3365 globals.h farsi.h arabic.h version.h
3366objects/ex_cmds2.o: ex_cmds2.c vim.h auto/config.h feature.h os_unix.h \
3367 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3368 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3369 proto.h globals.h farsi.h arabic.h version.h
3370objects/ex_docmd.o: ex_docmd.c vim.h auto/config.h feature.h os_unix.h \
3371 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3372 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3373 proto.h globals.h farsi.h arabic.h
3374objects/ex_eval.o: ex_eval.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3375 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3376 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3377 globals.h farsi.h arabic.h
3378objects/ex_getln.o: ex_getln.c vim.h auto/config.h feature.h os_unix.h \
3379 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3380 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3381 proto.h globals.h farsi.h arabic.h
3382objects/farsi.o: farsi.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3383 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3384 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3385 globals.h farsi.h arabic.h
3386objects/fileio.o: fileio.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3387 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3388 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3389 globals.h farsi.h arabic.h
3390objects/fold.o: fold.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3391 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3392 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3393 globals.h farsi.h arabic.h
3394objects/getchar.o: getchar.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3395 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3396 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3397 globals.h farsi.h arabic.h
3398objects/hardcopy.o: hardcopy.c vim.h auto/config.h feature.h os_unix.h \
3399 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3400 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3401 proto.h globals.h farsi.h arabic.h version.h
3402objects/hashtab.o: hashtab.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3403 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3404 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3405 globals.h farsi.h arabic.h
3406objects/if_cscope.o: if_cscope.c vim.h auto/config.h feature.h os_unix.h \
3407 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3408 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3409 proto.h globals.h farsi.h arabic.h if_cscope.h
3410objects/if_xcmdsrv.o: if_xcmdsrv.c vim.h auto/config.h feature.h os_unix.h \
3411 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3412 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3413 proto.h globals.h farsi.h arabic.h version.h
3414objects/json.o: json.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3415 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3416 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3417 globals.h farsi.h arabic.h
3418objects/list.o: list.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3419 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3420 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3421 globals.h farsi.h arabic.h
3422objects/main.o: main.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3423 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3424 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3425 globals.h farsi.h arabic.h
3426objects/mark.o: mark.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3427 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3428 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3429 globals.h farsi.h arabic.h
3430objects/memfile.o: memfile.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3431 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3432 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3433 globals.h farsi.h arabic.h
3434objects/memline.o: memline.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3435 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3436 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3437 globals.h farsi.h arabic.h
3438objects/menu.o: menu.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3439 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3440 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3441 globals.h farsi.h arabic.h
3442objects/message.o: message.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3443 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3444 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3445 globals.h farsi.h arabic.h
3446objects/misc1.o: misc1.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3447 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3448 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3449 globals.h farsi.h arabic.h version.h
3450objects/misc2.o: misc2.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3451 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3452 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3453 globals.h farsi.h arabic.h
3454objects/move.o: move.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3455 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3456 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3457 globals.h farsi.h arabic.h
3458objects/mbyte.o: mbyte.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3459 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3460 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3461 globals.h farsi.h arabic.h
3462objects/normal.o: normal.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3463 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3464 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3465 globals.h farsi.h arabic.h
3466objects/ops.o: ops.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h ascii.h \
3467 keymap.h term.h macros.h option.h structs.h regexp.h gui.h gui_beval.h \
3468 proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h globals.h farsi.h \
3469 arabic.h
3470objects/option.o: option.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3471 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3472 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3473 globals.h farsi.h arabic.h
3474objects/os_unix.o: os_unix.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3475 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3476 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3477 globals.h farsi.h arabic.h if_mzsch.h os_unixx.h
3478objects/pathdef.o: auto/pathdef.c vim.h auto/config.h feature.h os_unix.h \
3479 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3480 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3481 proto.h globals.h farsi.h arabic.h
3482objects/popupmnu.o: popupmnu.c vim.h auto/config.h feature.h os_unix.h \
3483 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3484 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3485 proto.h globals.h farsi.h arabic.h
3486objects/quickfix.o: quickfix.c vim.h auto/config.h feature.h os_unix.h \
3487 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3488 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3489 proto.h globals.h farsi.h arabic.h
3490objects/regexp.o: regexp.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3491 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3492 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3493 globals.h farsi.h arabic.h regexp_nfa.c
3494objects/screen.o: screen.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3495 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3496 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3497 globals.h farsi.h arabic.h
3498objects/search.o: search.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3499 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3500 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3501 globals.h farsi.h arabic.h
3502objects/sha256.o: sha256.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3503 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3504 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3505 globals.h farsi.h arabic.h
3506objects/spell.o: spell.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3507 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3508 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3509 globals.h farsi.h arabic.h
3510objects/spellfile.o: spellfile.c vim.h auto/config.h feature.h os_unix.h \
3511 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3512 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3513 proto.h globals.h farsi.h arabic.h
3514objects/syntax.o: syntax.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3515 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3516 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3517 globals.h farsi.h arabic.h
3518objects/tag.o: tag.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h ascii.h \
3519 keymap.h term.h macros.h option.h structs.h regexp.h gui.h gui_beval.h \
3520 proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h globals.h farsi.h \
3521 arabic.h
3522objects/term.o: term.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3523 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3524 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3525 globals.h farsi.h arabic.h
3526objects/ui.o: ui.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h ascii.h \
3527 keymap.h term.h macros.h option.h structs.h regexp.h gui.h gui_beval.h \
3528 proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h globals.h farsi.h \
3529 arabic.h
3530objects/undo.o: undo.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3531 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3532 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3533 globals.h farsi.h arabic.h
3534objects/userfunc.o: userfunc.c vim.h auto/config.h feature.h os_unix.h \
3535 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3536 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3537 proto.h globals.h farsi.h arabic.h
3538objects/version.o: version.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3539 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3540 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3541 globals.h farsi.h arabic.h version.h
3542objects/window.o: window.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3543 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3544 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3545 globals.h farsi.h arabic.h
3546objects/gui.o: gui.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h ascii.h \
3547 keymap.h term.h macros.h option.h structs.h regexp.h gui.h gui_beval.h \
3548 proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h globals.h farsi.h \
3549 arabic.h
3550objects/gui_gtk.o: gui_gtk.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3551 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3552 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3553 globals.h farsi.h arabic.h gui_gtk_f.h
3554objects/gui_gtk_f.o: gui_gtk_f.c vim.h auto/config.h feature.h os_unix.h \
3555 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3556 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3557 proto.h globals.h farsi.h arabic.h gui_gtk_f.h
3558objects/gui_motif.o: gui_motif.c vim.h auto/config.h feature.h os_unix.h \
3559 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3560 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3561 proto.h globals.h farsi.h arabic.h gui_xmebw.h ../pixmaps/alert.xpm \
3562 ../pixmaps/error.xpm ../pixmaps/generic.xpm ../pixmaps/info.xpm \
3563 ../pixmaps/quest.xpm gui_x11_pm.h ../pixmaps/tb_new.xpm \
3564 ../pixmaps/tb_open.xpm ../pixmaps/tb_close.xpm ../pixmaps/tb_save.xpm \
3565 ../pixmaps/tb_print.xpm ../pixmaps/tb_cut.xpm ../pixmaps/tb_copy.xpm \
3566 ../pixmaps/tb_paste.xpm ../pixmaps/tb_find.xpm \
3567 ../pixmaps/tb_find_next.xpm ../pixmaps/tb_find_prev.xpm \
3568 ../pixmaps/tb_find_help.xpm ../pixmaps/tb_exit.xpm \
3569 ../pixmaps/tb_undo.xpm ../pixmaps/tb_redo.xpm ../pixmaps/tb_help.xpm \
3570 ../pixmaps/tb_macro.xpm ../pixmaps/tb_make.xpm \
3571 ../pixmaps/tb_save_all.xpm ../pixmaps/tb_jump.xpm \
3572 ../pixmaps/tb_ctags.xpm ../pixmaps/tb_load_session.xpm \
3573 ../pixmaps/tb_save_session.xpm ../pixmaps/tb_new_session.xpm \
3574 ../pixmaps/tb_blank.xpm ../pixmaps/tb_maximize.xpm \
3575 ../pixmaps/tb_split.xpm ../pixmaps/tb_minimize.xpm \
3576 ../pixmaps/tb_shell.xpm ../pixmaps/tb_replace.xpm \
3577 ../pixmaps/tb_vsplit.xpm ../pixmaps/tb_maxwidth.xpm \
3578 ../pixmaps/tb_minwidth.xpm
3579objects/gui_xmdlg.o: gui_xmdlg.c vim.h auto/config.h feature.h os_unix.h \
3580 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3581 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3582 proto.h globals.h farsi.h arabic.h
3583objects/gui_xmebw.o: gui_xmebw.c vim.h auto/config.h feature.h os_unix.h \
3584 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3585 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3586 proto.h globals.h farsi.h arabic.h gui_xmebwp.h gui_xmebw.h
3587objects/gui_athena.o: gui_athena.c vim.h auto/config.h feature.h os_unix.h \
3588 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3589 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3590 proto.h globals.h farsi.h arabic.h gui_at_sb.h gui_x11_pm.h \
3591 ../pixmaps/tb_new.xpm ../pixmaps/tb_open.xpm ../pixmaps/tb_close.xpm \
3592 ../pixmaps/tb_save.xpm ../pixmaps/tb_print.xpm ../pixmaps/tb_cut.xpm \
3593 ../pixmaps/tb_copy.xpm ../pixmaps/tb_paste.xpm ../pixmaps/tb_find.xpm \
3594 ../pixmaps/tb_find_next.xpm ../pixmaps/tb_find_prev.xpm \
3595 ../pixmaps/tb_find_help.xpm ../pixmaps/tb_exit.xpm \
3596 ../pixmaps/tb_undo.xpm ../pixmaps/tb_redo.xpm ../pixmaps/tb_help.xpm \
3597 ../pixmaps/tb_macro.xpm ../pixmaps/tb_make.xpm \
3598 ../pixmaps/tb_save_all.xpm ../pixmaps/tb_jump.xpm \
3599 ../pixmaps/tb_ctags.xpm ../pixmaps/tb_load_session.xpm \
3600 ../pixmaps/tb_save_session.xpm ../pixmaps/tb_new_session.xpm \
3601 ../pixmaps/tb_blank.xpm ../pixmaps/tb_maximize.xpm \
3602 ../pixmaps/tb_split.xpm ../pixmaps/tb_minimize.xpm \
3603 ../pixmaps/tb_shell.xpm ../pixmaps/tb_replace.xpm \
3604 ../pixmaps/tb_vsplit.xpm ../pixmaps/tb_maxwidth.xpm \
3605 ../pixmaps/tb_minwidth.xpm
3606objects/gui_gtk_x11.o: gui_gtk_x11.c vim.h auto/config.h feature.h os_unix.h \
3607 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3608 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3609 proto.h globals.h farsi.h arabic.h auto/gui_gtk_gresources.h gui_gtk_f.h \
3610 ../runtime/vim32x32.xpm ../runtime/vim16x16.xpm ../runtime/vim48x48.xpm
3611objects/gui_x11.o: gui_x11.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3612 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3613 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3614 globals.h farsi.h arabic.h ../runtime/vim32x32.xpm \
3615 ../runtime/vim16x16.xpm ../runtime/vim48x48.xpm
3616objects/gui_at_sb.o: gui_at_sb.c vim.h auto/config.h feature.h os_unix.h \
3617 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3618 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3619 proto.h globals.h farsi.h arabic.h gui_at_sb.h
3620objects/gui_at_fs.o: gui_at_fs.c vim.h auto/config.h feature.h os_unix.h \
3621 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3622 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3623 proto.h globals.h farsi.h arabic.h gui_at_sb.h
3624objects/pty.o: pty.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h ascii.h \
3625 keymap.h term.h macros.h option.h structs.h regexp.h gui.h gui_beval.h \
3626 proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h globals.h farsi.h \
3627 arabic.h
3628objects/json_test.o: json_test.c main.c vim.h auto/config.h feature.h os_unix.h \
3629 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3630 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3631 proto.h globals.h farsi.h arabic.h json.c
3632objects/kword_test.o: kword_test.c main.c vim.h auto/config.h feature.h os_unix.h \
3633 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3634 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3635 proto.h globals.h farsi.h arabic.h charset.c mbyte.c
3636objects/memfile_test.o: memfile_test.c main.c vim.h auto/config.h feature.h \
3637 os_unix.h auto/osdef.h ascii.h keymap.h term.h macros.h option.h \
3638 structs.h regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h \
3639 ex_cmds.h spell.h proto.h globals.h farsi.h arabic.h memfile.c
3640objects/message_test.o: message_test.c main.c vim.h auto/config.h feature.h \
3641 os_unix.h auto/osdef.h ascii.h keymap.h term.h macros.h option.h \
3642 structs.h regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h \
3643 ex_cmds.h spell.h proto.h globals.h farsi.h arabic.h message.c
3644objects/hangulin.o: hangulin.c vim.h auto/config.h feature.h os_unix.h \
3645 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3646 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3647 proto.h globals.h farsi.h arabic.h
3648objects/if_lua.o: if_lua.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3649 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3650 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3651 globals.h farsi.h arabic.h
3652objects/if_mzsch.o: if_mzsch.c vim.h auto/config.h feature.h os_unix.h \
3653 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3654 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3655 proto.h globals.h farsi.h arabic.h if_mzsch.h mzscheme_base.c
3656objects/if_perl.o: auto/if_perl.c vim.h auto/config.h feature.h os_unix.h \
3657 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3658 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3659 proto.h globals.h farsi.h arabic.h
3660objects/if_perlsfio.o: if_perlsfio.c vim.h auto/config.h feature.h os_unix.h \
3661 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3662 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3663 proto.h globals.h farsi.h arabic.h
3664objects/if_python.o: if_python.c vim.h auto/config.h feature.h os_unix.h \
3665 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3666 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3667 proto.h globals.h farsi.h arabic.h if_py_both.h
3668objects/if_python3.o: if_python3.c vim.h auto/config.h feature.h os_unix.h \
3669 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3670 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3671 proto.h globals.h farsi.h arabic.h if_py_both.h
3672objects/if_tcl.o: if_tcl.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3673 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3674 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3675 globals.h farsi.h arabic.h
3676objects/if_ruby.o: if_ruby.c auto/config.h vim.h feature.h os_unix.h auto/osdef.h \
3677 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3678 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3679 globals.h farsi.h arabic.h version.h
3680objects/gui_beval.o: gui_beval.c vim.h auto/config.h feature.h os_unix.h \
3681 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3682 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3683 proto.h globals.h farsi.h arabic.h
3684objects/workshop.o: workshop.c auto/config.h integration.h vim.h feature.h \
3685 os_unix.h auto/osdef.h ascii.h keymap.h term.h macros.h option.h \
3686 structs.h regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h \
3687 ex_cmds.h spell.h proto.h globals.h farsi.h arabic.h version.h \
3688 workshop.h
3689objects/wsdebug.o: wsdebug.c
3690objects/integration.o: integration.c vim.h auto/config.h feature.h os_unix.h \
3691 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3692 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3693 proto.h globals.h farsi.h arabic.h integration.h
3694objects/netbeans.o: netbeans.c vim.h auto/config.h feature.h os_unix.h \
3695 auto/osdef.h ascii.h keymap.h term.h macros.h option.h structs.h \
3696 regexp.h gui.h gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h \
3697 proto.h globals.h farsi.h arabic.h version.h
3698objects/channel.o: channel.c vim.h auto/config.h feature.h os_unix.h auto/osdef.h \
3699 ascii.h keymap.h term.h macros.h option.h structs.h regexp.h gui.h \
3700 gui_beval.h proto/gui_beval.pro alloc.h ex_cmds.h spell.h proto.h \
3701 globals.h farsi.h arabic.h
3702objects/gui_gtk_gresources.o: auto/gui_gtk_gresources.c
3703