]> code.delx.au - gnu-emacs/blobdiff - nt/INSTALL
Merge from origin/emacs-25
[gnu-emacs] / nt / INSTALL
index c4e190f6f349a272d575d0a4c6ff54763bae675c..99a2f3988f91ca744fa59ebe5f6273374fa1c4eb 100644 (file)
@@ -1,17 +1,20 @@
                    Building and Installing Emacs on MS-Windows
                           using the MSYS and MinGW tools
 
-  Copyright (C) 2013-2015 Free Software Foundation, Inc.
+  Copyright (C) 2013-2016 Free Software Foundation, Inc.
   See the end of the file for license conditions.
 
 The MSYS/MinGW build described here is supported on versions of
-Windows starting with Windows 2000 and newer.  Windows 9X are not
-supported (but the Emacs binary produced by this build will run on
-Windows 9X as well).
+Windows starting with Windows XP and newer.  Building on Windows 2000
+and Windows 9X is not supported (but the Emacs binary produced by this
+build will run on Windows 9X and newer systems).
 
   Do not use this recipe with Cygwin.  For building on Cygwin, use the
   normal installation instructions, ../INSTALL.
 
+  For building Emacs using the MinGW64/MSYS2 toolchain, see the
+  instructions in the file INSTALL.W64 in this directory.
+
 * For the brave (a.k.a. "impatient"):
 
   For those who have a working MSYS/MinGW development environment and
@@ -75,6 +78,48 @@ Windows 9X as well).
   If these short instructions somehow fail, read the rest of this
   file.
 
+* Installing Git for Windows
+
+  Skip this section if you already have Git installed and configured,
+  or if you are building from the release tarball, not from the
+  development repository.
+
+  Git for Windows is available from this download page:
+
+    https://github.com/git-for-windows/git/releases
+
+  That page offers both 32-bit and 64-bit installations; pick the one
+  suitable for your OS.  In general, we recommend to install a 64-bit
+  Git if you have a 64-bit Windows system; the 32-bit Git will run on
+  64-bit Windows just fine, but might run into memory problems where
+  the 64-bit Git won't.
+
+  During Git installation, be sure to select the "Checkout as-is,
+  commit as-is" option from the "Configure line ending conversions"
+  dialog.  Otherwise, Git will convert text files to DOS-style CRLF
+  end-of-line (EOL) format, which will cause subtle problems when
+  building Emacs, because MSYS tools (see below) used to build Emacs
+  use binary file I/O that preserves the CR characters that get in the
+  way of some text-processing tools, like 'makeinfo' and the commands
+  invoked by the autogen.sh script.
+
+  If you already have Git installed and configured with some other EOL
+  conversion option, you will need to reconfigure it, removing the
+  following variables from all of your .gitconfig files:
+
+    core.eol
+    core.safecrlf
+    core.autocrlf
+
+  If you cloned the Emacs directory before changing these config
+  variables, you will have to delete the repository and re-clone it
+  after the change.
+
+  The instructions for cloning the Emacs repository can be found on
+  the Emacs's Savannah project page:
+
+    https://savannah.gnu.org/projects/emacs
+
 * Installing MinGW and MSYS
 
   Make sure you carefully read the following two sections in their
@@ -108,12 +153,37 @@ Windows 9X as well).
    . msys-base
    . mingw-developer-toolkit
 
+  When the installation ends, perform the post-installation steps
+  described on this page of the MinGW site:
+
+    http://www.mingw.org/wiki/Getting_Started
+
+  in the "After Installing You Should ..." section.  These steps are
+  important for making your installation complete, and in particular
+  will produce a desktop shortcut for running the MSYS Bash shell,
+  from which you will configure and build Emacs.  Once you've made the
+  shortcut, double-click on it to open the MSYS Bash shell window,
+  where you will proceed with the rest of these instructions.
+
+  In addition, we suggest to modify your system-wide Path variable to
+  include the 'bin' subdirectory of your top-level MinGW installation
+  directory, the one you specified to mingw-get ("C:\MinGW" by
+  default).  This will allow you to invoke the MinGW development
+  tools, like GCC, from the Windows cmd.exe shell windows or from
+  other Windows programs (including Emacs, after you build and install
+  it).
+
   (We recommend that you refrain from installing the MSYS Texinfo
   package, which is part of msys-base, because it might produce mixed
   EOL format when installing Info files.  Instead, install the MinGW
   port of Texinfo, see the ezwinports URL below.  To uninstall the
   MSYS Texinfo, after installing it as part of msys-base, invoke the
-  command "mingw-get remove msys-texinfo".)
+  command "mingw-get remove msys-texinfo", or mark "msys-texinfo" for
+  removal in the mingw-get GUI, then select Installation->Apply Changes.)
+
+  (Similarly, we recommend to refrain from installing the MinGW
+  Automake and Autoconf packages; instead, install their MSYS builds
+  available from the ezwinports site, see below.)
 
   At this point, you should be ready to configure and build Emacs in
   its basic configuration.  Skip to the "Generating the configure
@@ -122,7 +192,7 @@ Windows 9X as well).
   optional libraries near the end of this document, before you start
   the build.  Also, consider installing additional MinGW packages that
   are required/recommended, especially if you are building from the
-  repository, as described in the next section.
+  development repository, as described in the next section.
 
 ** Installing MinGW and MSYS manually
 
@@ -166,21 +236,21 @@ Windows 9X as well).
   been warned!
 
   Additional MinGW packages are required/recommended, especially if
-  you are building from the repository:
+  you are building from the development repository:
 
    . Texinfo (needed to produce the Info manuals when building from
      the repository, and for "make install")
 
      Available from http://sourceforge.net/projects/ezwinports/files/.
 
-   . gzip (needed to compress files during "make install")
+   . pkg-config (invoked by the configure script to look for optional
+     packages)
 
-     Available from http://gnuwin32.sourceforge.net/packages/gzip.htm.
+     Available from http://sourceforge.net/projects/ezwinports/files/.
 
-   . pkg-config (needed for building with some optional libraries,
-     such as GnuTLS and libxml2)
+   . gzip (needed to compress files during "make install")
 
-     Available from http://www.gtk.org/download/win32.php
+     Available from http://gnuwin32.sourceforge.net/packages/gzip.htm.
 
   Each package might list other packages as prerequisites on its
   download page (under "Runtime requirements"); download those as
@@ -235,6 +305,12 @@ Windows 9X as well).
   For example, use D:\MSYS or D:\usr\MSYS as the top-level directory
   from which you unpack all of the MSYS packages.
 
+  After installing Automake and Autoconf, make sure any of the *.m4
+  files you might have in your MinGW installation also exist in the
+  MSYS installation tree, in the share/aclocal directory.  Those *.m4
+  files which exist in the MinGW tree, but not in the MSYS tree should
+  be copied there.
+
   If/when you are confident in your MinGW/MSYS installation, and want
   to speed up the builds, we recommend installing a pre-release
   version of Make from here:
@@ -312,7 +388,12 @@ Windows 9X as well).
      Checking for automake (need at least version 1.11)...
      ok
      Your system has the required tools, running autoreconf...
-     You can now run `./configure'.
+     Installing git hooks...
+     You can now run './configure'.
+
+  If the script fails because it cannot find Git, you will need to
+  arrange for the MSYS Bash's PATH to include the Git's 'bin'
+  subdirectory, where there's the git.exe executable.
 
 * Configuring Emacs for MinGW:
 
@@ -392,13 +473,14 @@ Windows 9X as well).
   successful, will eventually produce a summary of the configuration
   similar to this:
 
-     Configured for `i686-pc-mingw32'.
+     Configured for 'i686-pc-mingw32'.
 
        Where should the build process find the source code?    /path/to/emacs/sources
        What compiler should emacs be built with?               gcc  -std=gnu99 -O0 -g3
-       Should Emacs use the GNU version of malloc?             yes
-       Should Emacs use a relocating allocator for buffers?    yes
-       Should Emacs use mmap(2) for buffer allocation?         no
+       Should Emacs use the GNU version of malloc?             no
+        (The GNU allocators don't work with this system configuration.)
+       Should Emacs use a relocating allocator for buffers?    no
+       Should Emacs use mmap(2) for buffer allocation?         yes
        What window system should Emacs use?                    w32
        What toolkit should Emacs use?                          none
        Where do we find X Windows header files?                NONE
@@ -408,13 +490,16 @@ Windows 9X as well).
        Does Emacs use -ljpeg?                                  yes
        Does Emacs use -ltiff?                                  yes
        Does Emacs use a gif library?                           yes
-       Does Emacs use -lpng?                                   yes
-       Does Emacs use -lrsvg-2?                                no
+       Does Emacs use a png library?                           yes
+       Does Emacs use -lrsvg-2?                                yes
        Does Emacs use imagemagick?                             no
+       Does Emacs support sound?                               no
        Does Emacs use -lgpm?                                   no
        Does Emacs use -ldbus?                                  no
        Does Emacs use -lgconf?                                 no
        Does Emacs use GSettings?                               no
+       Does Emacs use a file notification library?             yes (w32)
+       Does Emacs use access control lists?                    yes
        Does Emacs use -lselinux?                               no
        Does Emacs use -lgnutls?                                yes
        Does Emacs use -lxml2?                                  yes
@@ -422,6 +507,7 @@ Windows 9X as well).
        Does Emacs use -lm17n-flt?                              no
        Does Emacs use -lotf?                                   no
        Does Emacs use -lxft?                                   no
+       Does Emacs directly use zlib?                           yes
        Does Emacs use toolkit scroll bars?                     yes
 
   You are almost there, hang on.
@@ -545,14 +631,13 @@ Windows 9X as well).
   is in the PATH or otherwise accessible and that the binaries are
   compatible (for example, that they were built with the same compiler).
 
+  To support XPM images (required for color tool-bar icons), you will
+  need the libXpm library.  It is available from the ezwinports site,
+  http://sourceforge.net/projects/ezwinports/files/.
+
   For PNG images, we recommend to use versions 1.4.x and later of
   libpng, because previous versions had security issues.  You can find
-  precompiled libraries and headers on the GTK download page for
-  Windows (http://www.gtk.org/download/win32.php for 32-bit builds and
-  http://www.gtk.org/download/win64.php for 64-bit builds).  The
-  ezwinports site, http://sourceforge.net/projects/ezwinports/files/
-  also offers PNG (as well as other image libraries), which are
-  usually newer.
+  precompiled libraries and headers on the ezwinports site.
 
   Versions 1.4.0 and later of libpng are binary incompatible with
   earlier versions, so Emacs will only look for libpng libraries which
@@ -589,70 +674,32 @@ Windows 9X as well).
   libtiffN.dll or libtiff-N.dll or libtiff.dll.  These can be found on
   the ezwinports site.
 
-  Pre-built versions of librsvg and its dependencies can be found in
-  one of these places:
-
-  1. http://sourceforge.net/projects/ezwinports/files/
-
-     This site includes a minimal (as much as possible for librsvg)
-     build of the library and its dependencies; it is also more
-     up-to-date with the latest upstream versions.  However, it
-     currently only offers 32-bit builds.  For building Emacs, you
-     need to download from this site all of the following *-bin.zip
-     archives:
-
-       librsvg, gdk-pixbuf, cairo, glib
-
-     The 'bin' archives on this site include both header files and the
-     libraries needed for building with librsvg and for running Emacs.
-     The librsvg archive includes all the shared libraries needed to
-     run Emacs with SVG support; the other 3 packages are required
-     because the compiler needs to see their header files when
-     building Emacs.
-
-  2. GTK project download site for Windows (see above for 2 URLs,
-     either for 32-bit builds or 64-bit builds)
-
-     This is the official Windows download site of the GTK project.
-     Its builds of librsvg are fatter, but are currently the only
-     alternative for 64-bit builds.  The easiest way to obtain the
-     dependencies required for building from this site is to download
-     a pre-bundled GTK+ development environment for Windows.  If you
-     would nevertheless like to download only the packages that are
-     strictly required, then, as of the time of this writing, here's
-     the list of GTK+ packages you will need:
-
-        librsvg, pango, freetype-2.4.11, freetype-2.4.2, croco, cairo,
-        glib, gdk-pixbuf, fontconfig, libpng-1.4.x, libpng-1.5.x,
-        libffi, libxml2, zlib
-
-     The GTK download page provides 2 separate archives for each
-     package: a 'bin' (binary) archive with programs and DLLs, and a
-     'dev' (development) archive with header files, import libraries,
-     and pkg-config files; download and install both archives for each
-     package you need.  (Sources of each package are available in a
-     separate, 3rd archive.)
-
-     As you see, some libraries for using this site's librsvg are
-     needed in more than one version -- this is because librsvg and
-     some of its dependencies were linked against different versions
-     of those libraries, and will look only for those DLLs when you
-     invoke SVG function.  So there's a bit of "DLL hell" involved
-     here, but at least in theory this should work, as each library
-     will dynamically link only against its dependencies, even if
-     another version of the same library is already loaded.  In
-     particular, at least 2 different versions of libpng will have to
-     be installed on your machine.  When you install these libpng
-     versions, be sure to keep the header files and the pkg-config
-     files in sync, i.e. install both the 'bin' and 'dev' archives of
-     the same libpng version together.
+  Pre-built versions of librsvg and its dependencies can be found
+  here:
+
+    http://sourceforge.net/projects/ezwinports/files/
+
+    This site includes a minimal (as much as possible for librsvg)
+    build of the library and its dependencies; it is also more
+    up-to-date with the latest upstream versions.  However, it
+    currently only offers 32-bit builds.  For building Emacs, you need
+    to download from this site all of the following *-bin.zip
+    archives:
+
+      librsvg, gdk-pixbuf, cairo, glib
+
+    The 'bin' archives on this site include both header files and the
+    libraries needed for building with librsvg and for running Emacs.
+    The librsvg archive includes all the shared libraries needed to
+    run Emacs with SVG support; the other 3 packages are required
+    because the compiler needs to see their header files when building
+    Emacs.
 
   To use librsvg at runtime, ensure that librsvg and its dependencies
   are on your PATH, or in the same directory as the emacs.exe binary.
   If you are downloading from the ezwinports site, you only need to
   install a single archive, librsvg-X.Y.Z-w32-bin.zip, which includes
-  all the dependency DLLs.  For the GTK project site, download the
-  'bin' archives for each of the libraries mentioned above.
+  all the dependency DLLs.
 
   If you think you've got all the dependencies and SVG support is
   still not working, check your PATH for other libraries that shadow