OLD | NEW |
1 # Copyright 2015 Google Inc. | 1 # Copyright 2015 Google Inc. |
2 # | 2 # |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 # This file builds the PDF backend. | 5 # This file builds the PDF backend. |
6 { | 6 { |
7 'targets': [ | 7 'targets': [ |
8 { | 8 { |
9 'target_name': 'pdf', | 9 'target_name': 'pdf', |
10 'product_name': 'skia_pdf', | 10 'product_name': 'skia_pdf', |
11 'type': 'static_library', | 11 'type': 'static_library', |
12 'standalone_static_library': 1, | 12 'standalone_static_library': 1, |
| 13 'variables': { 'skia_pdf_use_sfntly%': 1, }, |
13 'dependencies': [ | 14 'dependencies': [ |
14 'skia_lib.gyp:skia_lib', | 15 'skia_lib.gyp:skia_lib', |
15 'skflate.gyp:skflate', | 16 'skflate.gyp:skflate', |
16 ], | 17 ], |
17 'includes': [ | 18 'includes': [ |
18 'pdf.gypi', | 19 'pdf.gypi', |
19 ], | 20 ], |
20 'include_dirs': [ | 21 'include_dirs': [ |
21 '../src/core', # needed to get SkGlyphCache.h and SkTextFormatParams.h | 22 '../src/core', # needed to get SkGlyphCache.h and SkTextFormatParams.h |
22 '../src/pdf', | 23 '../src/pdf', |
23 '../src/utils', # needed to get SkBitSet.h | 24 '../src/utils', # needed to get SkBitSet.h |
24 ], | 25 ], |
25 'sources': [ | 26 'sources': [ |
26 'pdf.gypi', # Makes the gypi appear in IDEs (but does not modify the bui
ld). | 27 'pdf.gypi', # Makes the gypi appear in IDEs (but does not modify the bui
ld). |
27 ], | 28 ], |
28 'conditions': [ | 29 'conditions': [ |
| 30 [ 'skia_pdf_use_sfntly and not skia_android_framework and \ |
| 31 skia_os in ["win", "android", "linux", "chromeos", "mac"]', |
| 32 { 'dependencies': [ 'sfntly.gyp:sfntly' ] } |
| 33 ], |
29 [ 'skia_android_framework', { | 34 [ 'skia_android_framework', { |
30 # Add SFTNLY support for PDF (which in turns depends on ICU) | 35 # Add SFTNLY support for PDF (which in turns depends on ICU) |
31 'include_dirs': [ | 36 'include_dirs': [ |
32 'external/sfntly/cpp/src', | 37 'external/sfntly/cpp/src', |
33 ], | 38 ], |
34 'libraries': [ | 39 'libraries': [ |
35 'libsfntly.a', | 40 'libsfntly.a', |
36 '-licuuc', | 41 '-licuuc', |
37 '-licui18n', | 42 '-licui18n', |
38 ], | 43 ], |
39 } | 44 } |
40 ], | 45 ], |
41 ], | 46 ], |
42 # This section makes all targets that depend on this target | 47 # This section makes all targets that depend on this target |
43 # #define SK_SUPPORT_PDF and have access to the pdf header files. | 48 # #define SK_SUPPORT_PDF and have access to the pdf header files. |
44 'direct_dependent_settings': { | 49 'direct_dependent_settings': { |
45 'defines': [ | 50 'defines': [ |
46 'SK_SUPPORT_PDF', | 51 'SK_SUPPORT_PDF', |
47 ], | 52 ], |
48 'include_dirs': [ | 53 'include_dirs': [ |
49 '../include/core', # SkDocument.h | 54 '../include/core', # SkDocument.h |
50 ], | 55 ], |
51 }, | 56 }, |
52 }, | 57 }, |
53 ], | 58 ], |
54 } | 59 } |
OLD | NEW |