Update copyright year to 2015
[emacs.git] / msdos / INSTALL
blobea698afc10a9960a05ac71c782cbb5b2790d74f9
1 GNU Emacs Installation Guide for the DJGPP (a.k.a. MS-DOS) port
3 Copyright (C) 1992, 1994, 1996-1997, 2000-2015 Free Software Foundation,
4 Inc.
5 See the end of the file for license conditions.
7 The DJGPP port of GNU Emacs builds and runs on all versions of
8 MS-Windows from version 3.X on, including Windows XP, Vista, and
9 Windows 7 (however, see below for issues with Windows Vista and 7).
10 Building on plain MS-DOS is supported only if long file names are
11 supported (e.g., with a specialized driver such as doslfn).
13 To build and install the DJGPP port, you need to have the DJGPP ports
14 of GCC (the GNU C compiler), GNU Make, rm, mv, cp, and sed, and
15 version 2.02 or later of DJGPP itself.  See the remarks in CONFIG.BAT
16 for more information about locations and versions.  The Emacs FAQ (see
17 info/efaq.info) includes pointers to Internet sites where you can find
18 the necessary utilities; search for "MS-DOS".  The configuration step
19 (see below) will test for these utilities and will refuse to continue
20 if any of them isn't found.
22 Bootstrapping Emacs or recompiling Lisp files in the `lisp'
23 subdirectory using the various targets in the lisp/Makefile file
24 requires additional utilities: `find' (from Findutils), GNU `echo' and
25 `test' (from Sh-utils or Coreutils), `ls' and `chmod' (from Fileutils
26 or Coreutils), `grep' (from Grep), and a port of Bash.  However, you
27 should not normally need to run lisp/Makefile, as all the Lisp files
28 are distributed in byte-compiled form as well.  As for bootstrapping
29 itself, you will only need that if you check-out development sources
30 from the Emacs source repository.
32 Building the DJGPP version of Emacs is supported only on systems which
33 support long file names (e.g. Windows 9X or Windows XP).  You need to
34 unpack Emacs distribution in a way that doesn't truncate the original
35 long filenames to the DOS 8.3 namespace; the easiest way to do this is
36 to use djtar program which comes with DJGPP, since it will behave
37 consistently with the rest of DJGPP tools.  Do _not_ disable the DJGPP
38 long-file-name support (a.k.a. "LFN") while building Emacs.
40 (By the time you read this, you have already unpacked the Emacs
41 distribution, but if the explanations above imply that you should have
42 done it differently, it's safer to delete the directory tree created
43 by the unpacking program and unpack Emacs again, than to risk running
44 into strange problems during the build process.)
46 To unpack Emacs with djtar, type this command:
48     djtar -x emacs.tgz
50 (This assumes that the Emacs distribution is called `emacs.tgz' on
51 your system.)
53 When unpacking Emacs is done, a directory called `emacs-XX.YY' will be
54 created, where XX.YY is the Emacs version.
56 If you want to print international characters, install the intlfonts
57 distribution.  For this, create a directory called `fonts' under the
58 `emacs-XX.YY' top-level directory created by unpacking emacs.tgz,
59 chdir into the directory `emacs-XX.YY/fonts', and type this:
61     djtar -x intlfonts.tgz
63 To build and install Emacs, chdir to the `emacs-XX.YY' directory and
64 type these commands:
66     config msdos
67     make install
69 Running "config msdos" checks for several programs that are required
70 to configure and build Emacs; if one of those programs is not found,
71 CONFIG.BAT stops and prints an error message.
73 On Windows NT and Windows 2000/XP/Vista/7, running "config msdos"
74 might print an error message like "VDM has been already loaded".  This
75 is because those systems have a program called `redir.exe' which is
76 incompatible with a program by the same name supplied with DJGPP,
77 which is used by config.bat.  To resolve this, move the DJGPP's `bin'
78 subdirectory to the front of your PATH environment variable.
80 Windows Vista/7 has several bugs in its DPMI server related to memory
81 allocation: it fails DPMI resize memory block function, and it
82 arbitrarily limits the default amount of DPMI memory to 32MB.  To work
83 around these bugs, first configure Emacs to use the `malloc' function
84 from the DJGPP library.  To this end, run CONFIG.BAT with the
85 "--with-system-malloc" option:
87     config --with-system-malloc msdos
88     make install
90 In addition, for Windows Vista you'll need to install Service Pack 1
91 (SP1) or later and enlarge its DPMI memory limit by setting the value
92 of this Registry key:
94   HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Wow\DpmiLimit
96 Create this key if it does not exist.  The value is a DWORD; setting
97 it to 536870912 should let Emacs use up to 512MB of memory.
99 If you have other problems, either building Emacs or running the
100 produced binary, look in the file etc/PROBLEMS for some known problems
101 related to the DJGPP port (search for "MS-DOS").
103 To install the international fonts, chdir to the intlfonts-X.Y
104 directory created when you unpacked the intlfonts distribution (X.Y is
105 the version number of the fonts' distribution), and type the following
106 command:
108     make bdf INSTALLDIR=..
110 After Make finishes, you may remove the directory intlfonts-X.Y; the
111 fonts are installed into the fonts/bdf subdirectory of the top-level
112 Emacs directory, and that is where Emacs will look for them by
113 default.
115 Building Emacs creates executable files in the src and lib-src
116 directories.  Installing the DJGPP port of Emacs moves these
117 executables to a sibling directory called bin.  For example, if you
118 build in directory C:/emacs, installing moves the executables from
119 C:/emacs/src and C:/emacs/lib-src to the directory C:/emacs/bin, so
120 you can then delete the subdirectories C:/emacs/src and
121 C:/emacs/lib-src if you wish.  The only subdirectories you need to
122 keep are bin, lisp, etc and info.  (If you installed intlfonts, keep
123 the fonts directory and all its subdirectories as well.)  The bin
124 subdirectory should be added to your PATH.  The msdos subdirectory
125 includes a PIF and an icon file for Emacs which you might find useful
126 if you run Emacs under MS Windows.
128 Emacs on MSDOS finds the lisp, etc and info directories by looking in
129 ../lisp, ../etc and ../info, starting from the directory where the
130 Emacs executable was run from.  You can override this by setting the
131 environment variables EMACSDATA (for the location of `etc' directory),
132 EMACSLOADPATH (for the location of `lisp' directory) and INFOPATH (for
133 the location of the `info' directory).
135 Emacs features which require asynchronous subprocesses that depend on
136 multitasking do not work in the DJGPP port.  Synchronous subprocesses
137 do work, so features such as compilation, grep, and Ispell run
138 synchronously, unlike on other platforms.
141 This file is part of GNU Emacs.
143 GNU Emacs is free software: you can redistribute it and/or modify
144 it under the terms of the GNU General Public License as published by
145 the Free Software Foundation, either version 3 of the License, or
146 (at your option) any later version.
148 GNU Emacs is distributed in the hope that it will be useful,
149 but WITHOUT ANY WARRANTY; without even the implied warranty of
150 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
151 GNU General Public License for more details.
153 You should have received a copy of the GNU General Public License
154 along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.