1 # Copyright 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
6 # This gypi file contains the Skia library.
7 # In component mode (shared_lib) it is folded into a single shared library with
8 # the Chrome-specific enhancements but in all other cases it is a separate lib.
10 # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!WARNING!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
11 # variables and defines should go in skia_common.gypi so they can be seen
12 # by files listed here and in skia_library_opts.gypi.
13 # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!WARNING!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
16 'skia_library_opts.gyp:skia_opts',
17 '../third_party/zlib/zlib.gyp:zlib',
21 '../third_party/skia/gyp/core.gypi',
22 '../third_party/skia/gyp/effects.gypi',
23 '../third_party/skia/gyp/pdf.gypi',
24 '../third_party/skia/gyp/utils.gypi',
28 '../third_party/skia/src/ports/SkImageDecoder_empty.cpp',
29 '../third_party/skia/src/images/SkScaledBitmapSampler.cpp',
31 '../third_party/skia/src/ports/SkFontConfigInterface_direct.cpp',
33 '../third_party/skia/src/fonts/SkFontMgr_fontconfig.cpp',
34 '../third_party/skia/src/ports/SkFontHost_fontconfig.cpp',
36 '../third_party/skia/src/fonts/SkFontMgr_indirect.cpp',
37 '../third_party/skia/src/fonts/SkRemotableFontMgr.cpp',
38 '../third_party/skia/src/ports/SkRemotableFontMgr_win_dw.cpp',
40 '../third_party/skia/src/ports/SkImageGenerator_none.cpp',
42 '../third_party/skia/src/ports/SkFontHost_FreeType.cpp',
43 '../third_party/skia/src/ports/SkFontHost_FreeType_common.cpp',
44 '../third_party/skia/src/ports/SkFontHost_mac.cpp',
45 '../third_party/skia/src/ports/SkFontHost_win.cpp',
46 "../third_party/skia/src/ports/SkFontMgr_android.cpp",
47 "../third_party/skia/src/ports/SkFontMgr_android_factory.cpp",
48 '../third_party/skia/src/ports/SkFontMgr_android_parser.cpp',
49 '../third_party/skia/src/ports/SkFontMgr_win_dw.cpp',
50 '../third_party/skia/src/ports/SkGlobalInitialization_chromium.cpp',
51 '../third_party/skia/src/ports/SkOSFile_posix.cpp',
52 '../third_party/skia/src/ports/SkOSFile_stdio.cpp',
53 '../third_party/skia/src/ports/SkOSFile_win.cpp',
54 '../third_party/skia/src/ports/SkScalerContext_win_dw.cpp',
55 '../third_party/skia/src/ports/SkTime_Unix.cpp',
56 '../third_party/skia/src/ports/SkTLS_pthread.cpp',
57 '../third_party/skia/src/ports/SkTLS_win.cpp',
58 '../third_party/skia/src/ports/SkTypeface_win_dw.cpp',
60 '../third_party/skia/src/sfnt/SkOTTable_name.cpp',
61 '../third_party/skia/src/sfnt/SkOTUtils.cpp',
64 # Exclude all unused files in skia utils.gypi file
66 '../third_party/skia/src/utils/SkBitmapHasher.cpp',
67 '../third_party/skia/src/utils/SkBoundaryPatch.cpp',
68 '../third_party/skia/src/utils/SkFrontBufferedStream.cpp',
69 '../third_party/skia/src/utils/SkCamera.cpp',
70 '../third_party/skia/src/utils/SkCubicInterval.cpp',
71 '../third_party/skia/src/utils/SkCullPoints.cpp',
72 '../third_party/skia/src/utils/SkDumpCanvas.cpp',
73 '../third_party/skia/src/utils/SkInterpolator.cpp',
74 '../third_party/skia/src/utils/SkLayer.cpp',
75 '../third_party/skia/src/utils/SkMD5.cpp',
76 '../third_party/skia/src/utils/SkMeshUtils.cpp',
77 '../third_party/skia/src/utils/SkNinePatch.cpp',
78 '../third_party/skia/src/utils/SkOSFile.cpp',
79 '../third_party/skia/src/utils/SkParsePath.cpp',
80 '../third_party/skia/src/utils/SkSHA1.cpp',
82 # We don't currently need to change thread affinity, so leave out this complexity for now.
83 "../third_party/skia/src/utils/SkThreadUtils_pthread_mach.cpp",
84 "../third_party/skia/src/utils/SkThreadUtils_pthread_linux.cpp",
87 '../third_party/skia/src/utils/win/SkAutoCoInitialize.cpp',
88 '../third_party/skia/src/utils/win/SkIStream.cpp',
89 '../third_party/skia/src/utils/win/SkWGL_win.cpp',
92 '../third_party/skia/src/fonts/SkGScalerContext.cpp',
96 '../third_party/skia/include/c',
97 '../third_party/skia/include/core',
98 '../third_party/skia/include/effects',
99 '../third_party/skia/include/images',
100 '../third_party/skia/include/lazy',
101 '../third_party/skia/include/pathops',
102 '../third_party/skia/include/pdf',
103 '../third_party/skia/include/pipe',
104 '../third_party/skia/include/ports',
105 '../third_party/skia/include/private',
106 '../third_party/skia/include/utils',
107 '../third_party/skia/src/core',
108 '../third_party/skia/src/opts',
109 '../third_party/skia/src/image',
110 '../third_party/skia/src/pdf',
111 '../third_party/skia/src/ports',
112 '../third_party/skia/src/sfnt',
113 '../third_party/skia/src/utils',
114 '../third_party/skia/src/lazy',
117 ['skia_support_gpu != 0', {
119 '../third_party/skia/gyp/gpu.gypi',
122 '<@(skgpu_null_gl_sources)',
126 '../third_party/skia/include/gpu',
127 '../third_party/skia/src/gpu',
130 ['skia_support_pdf == 0', {
132 ['exclude', '../third_party/skia/src/doc/SkDocument_PDF.cpp'],
133 ['exclude', '../third_party/skia/src/pdf/'],
136 ['skia_support_pdf == 1', {
138 '../third_party/sfntly/sfntly.gyp:sfntly',
145 "../third_party/skia/src/utils/SkThreadUtils_pthread.cpp",
146 "../third_party/skia/src/utils/SkThreadUtils_pthread_other.cpp",
150 # Keeping _pthread.cpp and _pthread_other.cpp
151 "../third_party/skia/src/utils/SkThreadUtils_win.cpp",
160 [ 'OS == "android" and target_arch == "arm"', {
162 '../third_party/skia/src/core/SkUtilsArm.cpp',
165 '../build/android/ndk.gyp:cpu_features',
168 [ 'desktop_linux == 1 or chromeos == 1', {
170 '../build/linux/system.gyp:fontconfig',
171 '../build/linux/system.gyp:freetype2',
172 '../third_party/icu/icu.gyp:icuuc',
176 '-Wno-unused-function',
179 [ 'use_cairo == 1 and use_pango == 1', {
181 '../build/linux/system.gyp:pangocairo',
184 [ 'OS=="win" or OS=="mac" or OS=="ios" or OS=="android"', {
186 '../third_party/skia/src/ports/SkFontConfigInterface_direct.cpp',
187 '../third_party/skia/src/ports/SkFontHost_fontconfig.cpp',
188 '../third_party/skia/src/fonts/SkFontMgr_fontconfig.cpp',
191 [ 'OS=="win" or OS=="mac" or OS=="ios"', {
193 '../third_party/skia/src/ports/SkFontHost_FreeType.cpp',
194 '../third_party/skia/src/ports/SkFontHost_FreeType_common.cpp',
198 [ 'OS == "android"', {
200 '../third_party/expat/expat.gyp:expat',
201 '../third_party/freetype-android/freetype.gyp:ft2',
203 # This exports a hard dependency because it needs to run its
204 # symlink action in order to expose the skia header files.
205 'hard_dependency': 1,
207 '../third_party/expat/files/lib',
209 },{ # not 'OS == "android"'
211 "../third_party/skia/src/ports/SkFontMgr_android_factory.cpp",
212 '../third_party/skia/src/ports/SkFontMgr_android_parser.cpp',
217 '../third_party/skia/include/utils/ios',
218 '../third_party/skia/include/utils/mac',
222 '$(SDKROOT)/System/Library/Frameworks/ImageIO.framework',
226 # This file is used on both iOS and Mac, so it should be removed
227 # from the ios and mac conditions and moved into the main sources
229 '../third_party/skia/src/utils/mac/SkStream_mac.cpp',
232 # The main skia_opts target does not currently work on iOS because the
233 # target architecture on iOS is determined at compile time rather than
234 # gyp time (simulator builds are x86, device builds are arm). As a
235 # temporary measure, this is a separate opts target for iOS-only, using
236 # the _none.cpp files to avoid architecture-dependent implementations.
238 'skia_library_opts.gyp:skia_opts_none',
241 'skia_library_opts.gyp:skia_opts',
245 'direct_dependent_settings': {
247 '../third_party/skia/include/utils/mac',
251 '../third_party/skia/include/utils/mac',
255 '$(SDKROOT)/System/Library/Frameworks/AppKit.framework',
259 '../third_party/skia/src/utils/mac/SkStream_mac.cpp',
264 '../third_party/skia/src/ports/SkOSFile_posix.cpp',
265 '../third_party/skia/src/ports/SkTime_Unix.cpp',
266 '../third_party/skia/src/ports/SkTLS_pthread.cpp',
269 '../third_party/skia/include/utils/win',
270 '../third_party/skia/src/utils/win',
272 },{ # not 'OS == "win"'
274 '../third_party/skia/src/ports/SkFontMgr_win_dw.cpp',
275 '../third_party/skia/src/ports/SkRemotableFontMgr_win_dw.cpp',
276 '../third_party/skia/src/ports/SkScalerContext_win_dw.cpp',
277 '../third_party/skia/src/ports/SkTypeface_win_dw.cpp',
279 '../third_party/skia/src/utils/win/SkDWrite.cpp',
280 '../third_party/skia/src/utils/win/SkDWriteFontFileStream.cpp',
281 '../third_party/skia/src/utils/win/SkDWriteGeometrySink.cpp',
282 '../third_party/skia/src/utils/win/SkHRESULT.cpp',
286 'target_conditions': [
287 # Pull in specific Mac files for iOS (which have been filtered out
288 # by file name rules).
291 ['include', 'SkFontHost_mac\\.cpp$',],
292 ['include', 'SkStream_mac\\.cpp$',],
293 ['include', 'SkCreateCGImageRef\\.cpp$',],
297 # SkFontHost_mac.cpp uses API deprecated in iOS 7.
299 '-Wno-deprecated-declarations',
305 'direct_dependent_settings': {
307 '../third_party/skia/include/core',
308 '../third_party/skia/include/effects',
309 '../third_party/skia/include/pdf',
310 '../third_party/skia/include/gpu',
311 '../third_party/skia/include/lazy',
312 '../third_party/skia/include/pathops',
313 '../third_party/skia/include/pipe',
314 '../third_party/skia/include/ports',
315 '../third_party/skia/include/utils',