OLD | NEW |
(Empty) | |
| 1 # |
| 2 # Copyright 2015 Google Inc. |
| 3 # |
| 4 # Use of this source code is governed by a BSD-style license that can be |
| 5 # found in the LICENSE file. |
| 6 # |
| 7 |
| 8 # GYP for building gpu |
| 9 { |
| 10 'variables': { |
| 11 'variables': |
| 12 { |
| 13 'vulkan_merged_into_skia%': '0', |
| 14 }, |
| 15 'vulkan_merged_into_skia%': '<(vulkan_merged_into_skia)', |
| 16 'conditions' : [ |
| 17 [ 'vulkan_merged_into_skia == 1', { |
| 18 'skia_gyp_path%': '../gyp', |
| 19 'skia_root_path%': '../', |
| 20 'vulkan_third_party_path%': '..\\third_party', |
| 21 }, { |
| 22 'skia_gyp_path%': '../skia/gyp', |
| 23 'skia_root_path%': '../skia', |
| 24 'vulkan_third_party_path%': '..\\..\\third_party', |
| 25 }], |
| 26 ], |
| 27 }, |
| 28 'target_defaults': { |
| 29 'defines': [ |
| 30 'VK_PROTOTYPES', |
| 31 ], |
| 32 'conditions': [ |
| 33 ['skia_os == "win"', { |
| 34 'all_dependent_settings': { |
| 35 'msvs_settings': { |
| 36 'VCLinkerTool': { |
| 37 'AdditionalDependencies': [ |
| 38 'vulkan-1.lib', |
| 39 'shaderc.lib', |
| 40 'shaderc_util.lib', |
| 41 'glslang.lib', |
| 42 'OSDependent.lib', |
| 43 'OGLCompiler.lib', |
| 44 'SPIRV-Tools.lib', |
| 45 'SPIRV.lib', |
| 46 ], |
| 47 }, |
| 48 }, |
| 49 }, |
| 50 'link_settings': { |
| 51 'configurations': { |
| 52 'Debug': { |
| 53 'msvs_settings': { |
| 54 'VCLinkerTool': { |
| 55 'AdditionalLibraryDirectories': [ |
| 56 '<(vulkan_third_party_path)\\vulkan\\', |
| 57 '<(vulkan_third_party_path)\\shaderc\\Debug\\', |
| 58 ], |
| 59 }, |
| 60 }, |
| 61 }, |
| 62 'Release': { |
| 63 'msvs_settings': { |
| 64 'VCLinkerTool': { |
| 65 'AdditionalLibraryDirectories': [ |
| 66 '<(vulkan_third_party_path)\\vulkan\\', |
| 67 '<(vulkan_third_party_path)\\shaderc\\Release\\', |
| 68 ], |
| 69 }, |
| 70 }, |
| 71 }, |
| 72 'Debug_x64': { |
| 73 'msvs_settings': { |
| 74 'VCLinkerTool': { |
| 75 'AdditionalLibraryDirectories': [ |
| 76 '<(vulkan_third_party_path)\\vulkan\\', |
| 77 '<(vulkan_third_party_path)\\shaderc\\Debug\\', |
| 78 ], |
| 79 }, |
| 80 }, |
| 81 }, |
| 82 'Release_x64': { |
| 83 'msvs_settings': { |
| 84 'VCLinkerTool': { |
| 85 'AdditionalLibraryDirectories': [ |
| 86 '<(vulkan_third_party_path)\\vulkan\\', |
| 87 '<(vulkan_third_party_path)\\shaderc\\Release\\', |
| 88 ], |
| 89 }, |
| 90 }, |
| 91 }, |
| 92 }, |
| 93 }, |
| 94 }], |
| 95 ['skia_os != "win"', { |
| 96 'sources/': [ ['exclude', '_win.(h|cpp)$'], |
| 97 ], |
| 98 }], |
| 99 ['skia_os != "mac"', { |
| 100 'sources/': [ ['exclude', '_mac.(h|cpp|m|mm)$'], |
| 101 ], |
| 102 }], |
| 103 ['skia_os != "linux" and skia_os != "chromeos"', { |
| 104 'sources/': [ ['exclude', '_glx.(h|cpp)$'], |
| 105 ], |
| 106 }], |
| 107 ['skia_os != "ios"', { |
| 108 'sources/': [ ['exclude', '_iOS.(h|cpp|m|mm)$'], |
| 109 ], |
| 110 }], |
| 111 ['skia_os != "android"', { |
| 112 'sources/': [ ['exclude', '_android.(h|cpp)$'], |
| 113 ], |
| 114 }], |
| 115 ['skia_os != "nacl"', { |
| 116 'sources/': [ ['exclude', '_nacl.(h|cpp)$'], |
| 117 ], |
| 118 }], |
| 119 ['skia_os == "nacl" or skia_egl == 0', { |
| 120 'sources/': [ ['exclude', '_egl.(h|cpp)$'], |
| 121 ], |
| 122 }], |
| 123 ['skia_os == "android"', { |
| 124 'sources/': [ ['exclude', 'GrGLCreateNativeInterface_egl.cpp'], |
| 125 ], |
| 126 }], |
| 127 ['skia_egl == 1', { |
| 128 'sources/': [ ['exclude', '_glx.(h|cpp)$'], |
| 129 ], |
| 130 }], |
| 131 # nullify the targets in this gyp file if skia_gpu is 0 |
| 132 [ 'skia_gpu == 0', { |
| 133 'sources/': [ |
| 134 ['exclude', '.*'], |
| 135 ], |
| 136 'defines/': [ |
| 137 ['exclude', '.*'], |
| 138 ], |
| 139 'include_dirs/': [ |
| 140 ['exclude', '.*'], |
| 141 ], |
| 142 'link_settings': { |
| 143 'libraries/': [ |
| 144 ['exclude', '.*'], |
| 145 ], |
| 146 }, |
| 147 'direct_dependent_settings': { |
| 148 'defines/': [ |
| 149 ['exclude', '.*'], |
| 150 ], |
| 151 'include_dirs/': [ |
| 152 ['exclude', '.*'], |
| 153 ], |
| 154 }, |
| 155 }], |
| 156 ], |
| 157 'direct_dependent_settings': { |
| 158 'conditions': [ |
| 159 [ 'skia_os == "win"', { |
| 160 'defines': [ |
| 161 'GR_GL_FUNCTION_TYPE=__stdcall', |
| 162 ], |
| 163 }], |
| 164 ], |
| 165 'include_dirs': [ |
| 166 '../include/gpu', |
| 167 '../third_party/' |
| 168 ], |
| 169 }, |
| 170 }, |
| 171 'targets': [ |
| 172 { |
| 173 'target_name': 'skgpu_vk', |
| 174 'product_name': 'skia_skgpu_vk', |
| 175 'type': 'static_library', |
| 176 'standalone_static_library': 1, |
| 177 'dependencies': [ |
| 178 '<(skia_gyp_path)/core.gyp:*', |
| 179 '<(skia_gyp_path)/utils.gyp:utils', |
| 180 '<(skia_gyp_path)/etc1.gyp:libetc1', |
| 181 '<(skia_gyp_path)/ktx.gyp:libSkKTX', |
| 182 ], |
| 183 'includes': [ |
| 184 'gpuVk.gypi', |
| 185 ], |
| 186 'include_dirs': [ |
| 187 '../include/gpu', |
| 188 '../src/gpu', |
| 189 '../third_party', |
| 190 '<(skia_root_path)/include/gpu', |
| 191 '<(skia_root_path)/include/private', |
| 192 '<(skia_root_path)/src/core', |
| 193 '<(skia_root_path)/src/gpu', |
| 194 '<(skia_root_path)/src/image/', |
| 195 ], |
| 196 'sources': [ |
| 197 '<@(skgpu_vk_sources)', |
| 198 'gpuVk.gypi', # Makes the gypi appear in IDEs (but does not modify the b
uild). |
| 199 ], |
| 200 }, |
| 201 ], |
| 202 } |
OLD | NEW |