blob: 6a5aa316b05c8b23a1e9b6f679151e8ac814d0a5 [file] [log] [blame]
Werner Lemberg59939242006-01-31 20:17:42 +00001This document contains instructions on how to build the FreeType
2library on Unix systems. This also works for emulations like Cygwin
3or MSys on Win32:
David Turner66cbc202003-03-20 07:04:40 +00004
5
Werner Lemberga16c4a72003-04-21 13:30:27 +00006 1. Ensure that you are using GNU Make
David Turner66cbc202003-03-20 07:04:40 +00007 -------------------------------------
8
Werner Lemberg59939242006-01-31 20:17:42 +00009 The FreeType build system _exclusively_ works with GNU Make. You
10 will not be able to compile the library with the instructions
11 below using any other alternative (including BSD Make).
David Turner66cbc202003-03-20 07:04:40 +000012
David Turner9750fcb2007-01-04 23:14:48 +000013 Check that you have GNU make by running the command:
Werner Lemberga7235262005-08-30 00:22:46 +000014
David Turner9750fcb2007-01-04 23:14:48 +000015 make -v
Werner Lemberga7235262005-08-30 00:22:46 +000016
David Turner9750fcb2007-01-04 23:14:48 +000017 This should dump some text that begins with:
Werner Lemberga16c4a72003-04-21 13:30:27 +000018
David Turner9750fcb2007-01-04 23:14:48 +000019 GNU Make <version number>
20 Copyright (C) <year> Free Software Foundation Inc.
David Turner66cbc202003-03-20 07:04:40 +000021
David Turner9750fcb2007-01-04 23:14:48 +000022 Note that version 3.78.1 or higher is *required*, or the build will
23 fail.
David Turner66cbc202003-03-20 07:04:40 +000024
David Turner9750fcb2007-01-04 23:14:48 +000025 It's also OK to have GNU Make under another name (e.g. 'gmake')
26 if you use the GNUMAKE trick described below.
27
28 As a special exception, 'makepp' can also be used to build
29 FreeType 2. See the file docs/MAKEPP for details
David Turner66cbc202003-03-20 07:04:40 +000030
31
David Turner9750fcb2007-01-04 23:14:48 +000032 2. Regenerate the configure script when needed
33 ----------------------------------------------
34
35 This only applies if you're building a CVS snapshot or checkout,
36 *not* if you grabbed the sources of an official release.
37
38 you need to invoke the "autogen.sh" script in the top-level
39 directory in order to re-generate the configure script for your
40 platform. Normally, this simply means typing:
41
42 sh autogen.sh <your configure options>
43
44 in case of problems, you may need to install or upgrade Automake,
45 Autoconf or Libtool. See README.CVS in the top-level directory for
46 the gory details.
47
48
49 3. Build and install the library
Werner Lemberga16c4a72003-04-21 13:30:27 +000050 --------------------------------
David Turner66cbc202003-03-20 07:04:40 +000051
Werner Lemberg59939242006-01-31 20:17:42 +000052 The following should work on all Unix systems where the `make'
David Turner66cbc202003-03-20 07:04:40 +000053 command invokes GNU Make:
54
Werner Lemberga16c4a72003-04-21 13:30:27 +000055 ./configure [options]
David Turner66cbc202003-03-20 07:04:40 +000056 make
57 make install (as root)
58
Werner Lemberg59939242006-01-31 20:17:42 +000059 The default installation path is `/usr/local'. It can be changed
Werner Lemberga16c4a72003-04-21 13:30:27 +000060 with the `--prefix=<path>' option. Example:
David Turner66cbc202003-03-20 07:04:40 +000061
Werner Lemberga16c4a72003-04-21 13:30:27 +000062 ./configure --prefix=/usr
63
Werner Lemberg59939242006-01-31 20:17:42 +000064 When using a different command to invoke GNU Make, use the GNUMAKE
65 variable. For example, if `gmake' is the command to use on your
David Turner66cbc202003-03-20 07:04:40 +000066 system, do something like:
67
Werner Lemberga16c4a72003-04-21 13:30:27 +000068 GNUMAKE=gmake ./configure [options]
David Turner66cbc202003-03-20 07:04:40 +000069 gmake
70 gmake install (as root)
71
Werner Lemberg59939242006-01-31 20:17:42 +000072 If this still doesn't work, there must be a problem with your
73 system (e.g., you are using a very old version of GNU Make).
Werner Lemberga16c4a72003-04-21 13:30:27 +000074
Werner Lemberg59939242006-01-31 20:17:42 +000075 It is possible to compile FreeType in a different directory.
76 Assuming the FreeType source files in directory `/src/freetype' a
Werner Lemberga16c4a72003-04-21 13:30:27 +000077 compilation in directory `foo' works as follows:
78
79 cd foo
80 /src/freetype/configure [options]
81 make
82 make install
David Turner66cbc202003-03-20 07:04:40 +000083
Werner Lemberg59939242006-01-31 20:17:42 +000084----------------------------------------------------------------------
David Turner66cbc202003-03-20 07:04:40 +000085
Werner Lemberg59939242006-01-31 20:17:42 +000086Copyright 2003, 2004, 2005, 2006 by
Werner Lemberg56c368c2005-06-04 23:00:25 +000087David Turner, Robert Wilhelm, and Werner Lemberg.
88
Werner Lemberg59939242006-01-31 20:17:42 +000089This file is part of the FreeType project, and may only be used,
90modified, and distributed under the terms of the FreeType project
91license, LICENSE.TXT. By continuing to use, modify, or distribute
92this file you indicate that you have read the license and understand
93and accept it fully.
Werner Lemberg56c368c2005-06-04 23:00:25 +000094
95
Werner Lemberg82a07e92006-10-12 06:20:44 +000096--- end of INSTALL.UNIX ---