# Copyright 2015 Google Inc. # # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. # GYP for building gpu { 'target_defaults': { 'conditions': [ ['skia_os != "win"', { 'sources/': [ ['exclude', '_win.(h|cpp)$'], ], }], ['skia_os != "mac"', { 'sources/': [ ['exclude', '_mac.(h|cpp|m|mm)$'], ], }], ['skia_os != "linux"', { 'sources/': [ ['exclude', '_glx.(h|cpp)$'], ], }], ['skia_os != "ios"', { 'sources/': [ ['exclude', '_iOS.(h|cpp|m|mm)$'], ], }], ['skia_os != "android"', { 'sources/': [ ['exclude', '_android.(h|cpp)$'], ], }], ['skia_egl == 0', { 'sources/': [ ['exclude', '_egl.(h|cpp)$'], ], }], ['skia_os == "android"', { 'sources/': [ ['exclude', 'GrGLCreateNativeInterface_egl.cpp'], ], }], ['skia_egl == 1', { 'sources/': [ ['exclude', '_glx.(h|cpp)$'], ], }], # nullify the targets in this gyp file if skia_gpu is 0 [ 'skia_gpu == 0', { 'sources/': [ ['exclude', '.*'], ], 'defines/': [ ['exclude', '.*'], ], 'include_dirs/': [ ['exclude', '.*'], ], 'link_settings': { 'libraries/': [ ['exclude', '.*'], ], }, 'direct_dependent_settings': { 'defines/': [ ['exclude', '.*'], ], 'include_dirs/': [ ['exclude', '.*'], ], }, }], ], 'direct_dependent_settings': { 'include_dirs': [ '../include/gpu', ], }, }, 'targets': [ { 'target_name': 'skgpu', 'product_name': 'skia_skgpu', 'type': 'static_library', 'standalone_static_library': 1, 'dependencies': [ 'core.gyp:*', 'utils.gyp:utils', 'etc1.gyp:libetc1', 'ktx.gyp:libSkKTX', 'sksl.gyp:sksl', ], 'include_dirs': [ '../include/gpu', '../include/private', '../src/core', '../src/gpu', '../src/image/', '../src/sksl', ], 'sources': [ ' android.mk generator doesn't seem to like cpp files # in directories outside of src, bench, or dm. Until this gets fixed # I just start the path in the src directory. '<(skia_src_path)/../tools/viewer/sk_app/WindowContext.cpp', '<(skia_src_path)/../tools/viewer/sk_app/VulkanWindowContext.cpp', '<(skia_src_path)/../tools/viewer/sk_app/android/VulkanWindowContext_android.cpp' ], }], ], }, { 'sources!': [ '