Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
michael@0 | 1 | Due to our use of `libtool' to generate and install the FreeType 2 |
michael@0 | 2 | libraries on Unix systems, as well as other historical events, it is |
michael@0 | 3 | generally very difficult to know precisely which release of the font |
michael@0 | 4 | engine is installed on a given system. |
michael@0 | 5 | |
michael@0 | 6 | This file tries to explain why and to document ways to properly detect |
michael@0 | 7 | FreeType on Unix. |
michael@0 | 8 | |
michael@0 | 9 | |
michael@0 | 10 | 1. Version and Release numbers |
michael@0 | 11 | ------------------------------ |
michael@0 | 12 | |
michael@0 | 13 | For each new public release of FreeType 2, there are generally *three* |
michael@0 | 14 | distinct `version' numbers to consider: |
michael@0 | 15 | |
michael@0 | 16 | * The official FreeType 2 release number, like 2.3.1 or 2.4.10. |
michael@0 | 17 | |
michael@0 | 18 | * The libtool (and Unix) specific version number, like 13.0.7. This |
michael@0 | 19 | is what `freetype-config --version' returns. |
michael@0 | 20 | |
michael@0 | 21 | * The platform-specific shared object number, used for example when |
michael@0 | 22 | the library is installed as `/usr/lib/libfreetype.so.6.7.1'. |
michael@0 | 23 | |
michael@0 | 24 | The platform-specific number is, unsurprisingly, platform-specific and |
michael@0 | 25 | varies with the operating system you are using (several variants of |
michael@0 | 26 | Linux, FreeBSD, Solaris, etc.). You should thus _never_ use it, even |
michael@0 | 27 | for simple tests. |
michael@0 | 28 | |
michael@0 | 29 | The libtool-specific number does not equal the release number but is |
michael@0 | 30 | tied to it. |
michael@0 | 31 | |
michael@0 | 32 | The release number is available at *compile* time through the following |
michael@0 | 33 | macros defined in FT_FREETYPE_H: |
michael@0 | 34 | |
michael@0 | 35 | - FREETYPE_MAJOR: major release number |
michael@0 | 36 | - FREETYPE_MINOR: minor release number |
michael@0 | 37 | - FREETYPE_PATCH: patch release number |
michael@0 | 38 | |
michael@0 | 39 | See below for a small autoconf fragment. |
michael@0 | 40 | |
michael@0 | 41 | The release number is also available at *runtime* through the |
michael@0 | 42 | `FT_Library_Version' API. |
michael@0 | 43 | |
michael@0 | 44 | |
michael@0 | 45 | 2. History |
michael@0 | 46 | ---------- |
michael@0 | 47 | |
michael@0 | 48 | The following table gives, for all releases since 2.3.0, the |
michael@0 | 49 | corresponding libtool number, as well as the shared object number found |
michael@0 | 50 | on _most_ systems, but not all of them: |
michael@0 | 51 | |
michael@0 | 52 | |
michael@0 | 53 | release libtool so |
michael@0 | 54 | ------------------------------- |
michael@0 | 55 | 2.5.3 17.2.11 6.11.2 |
michael@0 | 56 | 2.5.2 17.1.11 6.11.1 |
michael@0 | 57 | 2.5.1 17.0.11 6.11.0 |
michael@0 | 58 | 2.5.0 16.2.10 6.10.2 |
michael@0 | 59 | 2.4.12 16.1.10 6.10.1 |
michael@0 | 60 | 2.4.11 16.0.10 6.10.0 |
michael@0 | 61 | 2.4.10 15.0.9 6.9.0 |
michael@0 | 62 | 2.4.9 14.1.8 6.8.1 |
michael@0 | 63 | 2.4.8 14.0.8 6.8.0 |
michael@0 | 64 | 2.4.7 13.2.7 6.7.2 |
michael@0 | 65 | 2.4.6 13.1.7 6.7.1 |
michael@0 | 66 | 2.4.5 13.0.7 6.7.0 |
michael@0 | 67 | 2.4.4 12.2.6 6.6.2 |
michael@0 | 68 | 2.4.3 12.1.6 6.6.1 |
michael@0 | 69 | 2.4.2 12.0.6 6.6.0 |
michael@0 | 70 | 2.4.1 11.1.5 6.5.1 |
michael@0 | 71 | 2.4.0 11.0.5 6.5.0 |
michael@0 | 72 | 2.3.12 10.0.4 6.4.0 |
michael@0 | 73 | 2.3.11 9.22.3 6.3.22 |
michael@0 | 74 | 2.3.10 9.21.3 6.3.21 |
michael@0 | 75 | 2.3.9 9.20.3 6.3.20 |
michael@0 | 76 | 2.3.8 9.19.3 6.3.19 |
michael@0 | 77 | 2.3.7 9.18.3 6.3.18 |
michael@0 | 78 | 2.3.6 9.17.3 6.3.17 |
michael@0 | 79 | 2.3.5 9.16.3 6.3.16 |
michael@0 | 80 | 2.3.4 9.15.3 6.3.15 |
michael@0 | 81 | 2.3.3 9.14.3 6.3.14 |
michael@0 | 82 | 2.3.2 9.13.3 6.3.13 |
michael@0 | 83 | 2.3.1 9.12.3 6.3.12 |
michael@0 | 84 | 2.3.0 9.11.3 6.3.11 |
michael@0 | 85 | |
michael@0 | 86 | |
michael@0 | 87 | 3. Autoconf Code Fragment |
michael@0 | 88 | ------------------------- |
michael@0 | 89 | |
michael@0 | 90 | Lars Clausen contributed the following autoconf fragment to detect which |
michael@0 | 91 | version of FreeType is installed on a system. This one tests for a |
michael@0 | 92 | version that is at least 2.0.9; you should change it to check against |
michael@0 | 93 | other release numbers. |
michael@0 | 94 | |
michael@0 | 95 | |
michael@0 | 96 | AC_MSG_CHECKING([whether FreeType version is 2.0.9 or higher]) |
michael@0 | 97 | old_CPPFLAGS="$CPPFLAGS" |
michael@0 | 98 | CPPFLAGS=`freetype-config --cflags` |
michael@0 | 99 | AC_TRY_CPP([ |
michael@0 | 100 | |
michael@0 | 101 | #include <ft2build.h> |
michael@0 | 102 | #include FT_FREETYPE_H |
michael@0 | 103 | #if (FREETYPE_MAJOR*1000 + FREETYPE_MINOR)*1000 + FREETYPE_PATCH < 2000009 |
michael@0 | 104 | #error Freetype version too low. |
michael@0 | 105 | #endif |
michael@0 | 106 | ], |
michael@0 | 107 | [AC_MSG_RESULT(yes) |
michael@0 | 108 | FREETYPE_LIBS=`freetype-config --libs` |
michael@0 | 109 | AC_SUBST(FREETYPE_LIBS) |
michael@0 | 110 | AC_DEFINE(HAVE_FREETYPE,1,[Define if you have the FreeType2 library]) |
michael@0 | 111 | CPPFLAGS="$old_CPPFLAGS"], |
michael@0 | 112 | [AC_MSG_ERROR([Need FreeType library version 2.0.9 or higher])]) |
michael@0 | 113 | |
michael@0 | 114 | ------------------------------------------------------------------------ |
michael@0 | 115 | |
michael@0 | 116 | Copyright 2002-2014 by |
michael@0 | 117 | David Turner, Robert Wilhelm, and Werner Lemberg. |
michael@0 | 118 | |
michael@0 | 119 | This file is part of the FreeType project, and may only be used, |
michael@0 | 120 | modified, and distributed under the terms of the FreeType project |
michael@0 | 121 | license, LICENSE.TXT. By continuing to use, modify, or distribute this |
michael@0 | 122 | file you indicate that you have read the license and understand and |
michael@0 | 123 | accept it fully. |
michael@0 | 124 | |
michael@0 | 125 | |
michael@0 | 126 | --- end of VERSION.DLL --- |