OLD | NEW |
1 # Target for building freetype. | 1 # Target for building freetype. |
2 { | 2 { |
3 'targets': [ | 3 'targets': [ |
4 { | 4 { |
5 'target_name': 'freetype', | 5 'target_name': 'freetype', |
6 'type': 'none', | 6 'type': 'none', |
7 'conditions': [ | 7 'conditions': [ |
8 [ 'skia_os in ["linux", "freebsd", "openbsd", "solaris", "chromeos"]', { | 8 [ 'skia_freetype_static', |
9 'direct_dependent_settings': { | 9 { |
10 'include_dirs' : [ | 10 'dependencies': [ |
11 '/usr/include/freetype2', | 11 'freetype_static' |
12 ], | 12 ], |
13 'link_settings': { | 13 'export_dependent_settings': [ |
14 'libraries': [ | 14 'freetype_static' |
15 '-lfreetype', | 15 ], |
| 16 'conditions': [ |
| 17 [ 'skia_os in ["android", "nacl"]', |
| 18 { |
| 19 'direct_dependent_settings': { |
| 20 'defines': [ |
| 21 # Both Android and NaCl provide at least FreeType 2.4.0 |
| 22 'SK_FONTHOST_FREETYPE_RUNTIME_VERSION=0x020400', |
| 23 'SK_CAN_USE_DLOPEN=0', |
| 24 ], |
| 25 } |
| 26 } |
| 27 ] |
| 28 ], |
| 29 }, { # (not skia_freetype_static) |
| 30 # dynamic linking depends on the OS: |
| 31 'conditions': [ |
| 32 [ 'skia_os in ["linux", "freebsd", "openbsd", "solaris", "chromeos
"]', |
| 33 { |
| 34 'direct_dependent_settings': { |
| 35 'include_dirs' : [ |
| 36 '/usr/include/freetype2', |
| 37 ], |
| 38 'link_settings': { |
| 39 'libraries': [ |
| 40 '-lfreetype', |
| 41 ], |
| 42 }, |
| 43 'defines': [ |
| 44 # The font host requires at least FreeType 2.3.0 |
| 45 # at runtime. |
| 46 'SK_FONTHOST_FREETYPE_RUNTIME_VERSION=0x020300', |
| 47 'SK_CAN_USE_DLOPEN=1', |
| 48 ], |
| 49 } |
| 50 }, |
16 ], | 51 ], |
17 'defines': [ | 52 [ 'skia_android_framework', |
18 #The font host requires at least FreeType 2.3.0 at runtime. | 53 { |
19 'SK_FONTHOST_FREETYPE_RUNTIME_VERSION=0x020300',\ | 54 'direct_dependent_settings': { |
20 'SK_CAN_USE_DLOPEN=1', | 55 'defines': [ |
| 56 # Android provides at least FreeType 2.4.0 |
| 57 'SK_FONTHOST_FREETYPE_RUNTIME_VERSION=0x020400', |
| 58 'SK_CAN_USE_DLOPEN=0', |
| 59 ], |
| 60 }, |
| 61 'include_dirs': [ |
| 62 'external/expat/lib', |
| 63 'external/freetype/include', |
| 64 ], |
| 65 'libraries': [ |
| 66 '-lft2', |
| 67 ], |
| 68 } |
21 ], | 69 ], |
22 } | |
23 }, | |
24 }], | |
25 [ 'skia_os in ["android", "nacl"]', { | |
26 'dependencies': [ | |
27 'freetype_static' | |
28 ], | |
29 'export_dependent_settings': [ | |
30 'freetype_static' | |
31 ], | |
32 'direct_dependent_settings': { | |
33 'defines': [ | |
34 # Both Android and NaCl provide at least FreeType 2.4.0 | |
35 'SK_FONTHOST_FREETYPE_RUNTIME_VERSION=0x020400', | |
36 'SK_CAN_USE_DLOPEN=0', | |
37 ], | 70 ], |
38 }, | 71 } |
39 }], | 72 ], |
40 [ 'skia_android_framework', { | |
41 'include_dirs': [ | |
42 'external/expat/lib', | |
43 'external/freetype/include', | |
44 ], | |
45 'libraries': [ | |
46 '-lft2', | |
47 ], | |
48 # Remove these, and use the system's freetype instead. | |
49 'dependencies!': [ | |
50 'freetype_static', | |
51 ], | |
52 'export_dependent_settings!': [ | |
53 'freetype_static', | |
54 ] | |
55 }], | |
56 ], | 73 ], |
57 }, | 74 }, |
58 { | 75 { |
59 'target_name': 'freetype_static', | 76 'target_name': 'freetype_static', |
60 'type': 'static_library', | 77 'type': 'static_library', |
61 'standalone_static_library': 1, | 78 'standalone_static_library': 1, |
62 'dependencies': [ | 79 'dependencies': [ |
63 # we are dependent upon PNG for color emoji glyphs | 80 # we are dependent upon PNG for color emoji glyphs |
64 'images.gyp:images' | 81 'libpng.gyp:libpng', |
65 ], | 82 ], |
66 'includes': [ | 83 'includes': [ |
67 # common freetype sources needed for both the base Skia build and the | 84 # common freetype sources needed for both the base Skia build and the |
68 # libpoppler build for testing only | 85 # libpoppler build for testing only |
69 'freetype.gypi', | 86 'freetype.gypi', |
70 ], | 87 ], |
71 'include_dirs': [ | 88 'include_dirs': [ |
72 '../third_party/freetype/include_overrides', | 89 '../third_party/freetype/include_overrides', |
73 ], | 90 ], |
74 'direct_dependent_settings': { | 91 'direct_dependent_settings': { |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
112 '../third_party/externals/freetype/src/type1/type1.c', | 129 '../third_party/externals/freetype/src/type1/type1.c', |
113 '../third_party/externals/freetype/src/type42/type42.c', | 130 '../third_party/externals/freetype/src/type42/type42.c', |
114 '../third_party/externals/freetype/src/winfonts/winfnt.c', | 131 '../third_party/externals/freetype/src/winfonts/winfnt.c', |
115 | 132 |
116 '../third_party/externals/freetype/src/gzip/ftgzip.c', | 133 '../third_party/externals/freetype/src/gzip/ftgzip.c', |
117 '../third_party/externals/freetype/src/lzw/ftlzw.c', | 134 '../third_party/externals/freetype/src/lzw/ftlzw.c', |
118 ], | 135 ], |
119 }, | 136 }, |
120 ], | 137 ], |
121 } | 138 } |
OLD | NEW |