| OLD | NEW |
| 1 # Copyright 2012 The Android Open Source Project | 1 # Copyright 2012 The Android Open Source Project |
| 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 | 5 |
| 6 { | 6 { |
| 7 # Get ready for the ugly... | 7 # Get ready for the ugly... |
| 8 # | 8 # |
| 9 # - We have to nest our variables dictionaries multiple levels deep, so that | 9 # - We have to nest our variables dictionaries multiple levels deep, so that |
| 10 # this and other gyp files can rely on previously-set variable values in | 10 # this and other gyp files can rely on previously-set variable values in |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 # We use 'skia_os' instead of 'OS' throughout our gyp files, to allow | 43 # We use 'skia_os' instead of 'OS' throughout our gyp files, to allow |
| 44 # for cross-compilation (e.g. building for either MacOS or iOS on Mac). | 44 # for cross-compilation (e.g. building for either MacOS or iOS on Mac). |
| 45 # We set it automatically based on 'OS' (the host OS), but allow the | 45 # We set it automatically based on 'OS' (the host OS), but allow the |
| 46 # user to override it via GYP_DEFINES if they like. | 46 # user to override it via GYP_DEFINES if they like. |
| 47 'skia_os%': '<(OS)', | 47 'skia_os%': '<(OS)', |
| 48 | 48 |
| 49 'skia_android_framework%': 0, | 49 'skia_android_framework%': 0, |
| 50 'skia_arch_type%': 'x86', | 50 'skia_arch_type%': 'x86', |
| 51 'arm_version%': 0, | 51 'arm_version%': 0, |
| 52 'arm_neon%': 0, | 52 'arm_neon%': 0, |
| 53 'skia_egl%': 0, | |
| 54 }, | 53 }, |
| 55 | 54 |
| 56 # Re-define all variables defined within the level-3 'variables' dict, | 55 # Re-define all variables defined within the level-3 'variables' dict, |
| 57 # so that siblings of the level-2 'variables' dict can see them. | 56 # so that siblings of the level-2 'variables' dict can see them. |
| 58 # (skia_os will depend on skia_android_framework.) | 57 # (skia_os will depend on skia_android_framework.) |
| 59 'skia_android_framework%': '<(skia_android_framework)', | 58 'skia_android_framework%': '<(skia_android_framework)', |
| 60 'skia_arch_type%': '<(skia_arch_type)', | 59 'skia_arch_type%': '<(skia_arch_type)', |
| 61 'arm_version%': '<(arm_version)', | 60 'arm_version%': '<(arm_version)', |
| 62 'arm_neon%': '<(arm_neon)', | 61 'arm_neon%': '<(arm_neon)', |
| 63 'skia_egl%': '<(skia_egl)', | |
| 64 | 62 |
| 65 'conditions': [ | 63 'conditions': [ |
| 66 [ 'skia_android_framework == 1', { | 64 [ 'skia_android_framework == 1', { |
| 67 'skia_os%': 'android', | 65 'skia_os%': 'android', |
| 68 'skia_chrome_utils%': 0, | 66 'skia_chrome_utils%': 0, |
| 69 'skia_use_system_json%': 1, | 67 'skia_use_system_json%': 1, |
| 70 }, { | 68 }, { |
| 71 'skia_os%': '<(skia_os)', | 69 'skia_os%': '<(skia_os)', |
| 72 'skia_chrome_utils%': 1, | 70 'skia_chrome_utils%': 1, |
| 73 'skia_use_system_json%': 0, | 71 'skia_use_system_json%': 0, |
| 74 }], | 72 }], |
| 75 [ 'skia_os == "win"', { | 73 [ 'skia_os == "win"', { |
| 76 'os_posix%': 0, | 74 'os_posix%': 0, |
| 77 }, { | 75 }, { |
| 78 'os_posix%': 1, | 76 'os_posix%': 1, |
| 79 }], | 77 }], |
| 80 [ 'skia_os in ["linux"]', { | 78 [ 'skia_os in ["linux"]', { |
| 81 'skia_poppler_enabled%': 1, | 79 'skia_poppler_enabled%': 1, |
| 82 }, { | 80 }, { |
| 83 'skia_poppler_enabled%': 0, | 81 'skia_poppler_enabled%': 0, |
| 84 }], | 82 }], |
| 85 [ 'skia_os in ["linux", "freebsd", "openbsd", "solaris", "mac"] or skia_
arch_type == "arm64"', { | 83 [ 'skia_os in ["linux", "freebsd", "openbsd", "solaris", "mac"] or skia_
arch_type == "arm64"', { |
| 86 'skia_arch_width%': 64, | 84 'skia_arch_width%': 64, |
| 87 }, { | 85 }, { |
| 88 'skia_arch_width%': 32, | 86 'skia_arch_width%': 32, |
| 89 }], | 87 }], |
| 90 [ 'skia_os == "android"', { | 88 [ 'skia_os == "android"', { |
| 91 'skia_static_initializers%': 0, | 89 'skia_static_initializers%': 0, |
| 92 'skia_egl%': 1, | |
| 93 }, { | 90 }, { |
| 94 'skia_static_initializers%': 1, | 91 'skia_static_initializers%': 1, |
| 95 }], | 92 }], |
| 96 [ 'skia_os == "ios"', { | 93 [ 'skia_os == "ios"', { |
| 97 'skia_arch_type%': 'arm', | 94 'skia_arch_type%': 'arm', |
| 98 'arm_version%': 7, | 95 'arm_version%': 7, |
| 99 'arm_neon%': 0, # neon asm files known not to work with the ios build | 96 'arm_neon%': 0, # neon asm files known not to work with the ios build |
| 100 }], | 97 }], |
| 101 [ 'skia_os in "nacl"', { | |
| 102 'skia_egl%': 1, | |
| 103 }], | |
| 104 [ 'skia_os in ["android", "nacl"] and not skia_android_framework', | 98 [ 'skia_os in ["android", "nacl"] and not skia_android_framework', |
| 105 # skia_freetype_static - on OS variants that normally would | 99 # skia_freetype_static - on OS variants that normally would |
| 106 # dynamically link the system FreeType library, don't do | 100 # dynamically link the system FreeType library, don't do |
| 107 # that; instead statically link to the version in | 101 # that; instead statically link to the version in |
| 108 # third_party/freetype and third_party/externals/freetype. | 102 # third_party/freetype and third_party/externals/freetype. |
| 109 { | 103 { |
| 110 'skia_freetype_static%': '1', | 104 'skia_freetype_static%': '1', |
| 111 }, { | 105 }, { |
| 112 'skia_freetype_static%': '0', | 106 'skia_freetype_static%': '0', |
| 113 } | 107 } |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 232 'skia_shared_lib%': '<(skia_shared_lib)', | 226 'skia_shared_lib%': '<(skia_shared_lib)', |
| 233 'skia_opencl%': '<(skia_opencl)', | 227 'skia_opencl%': '<(skia_opencl)', |
| 234 'skia_force_distancefield_fonts%': '<(skia_force_distancefield_fonts)', | 228 'skia_force_distancefield_fonts%': '<(skia_force_distancefield_fonts)', |
| 235 'skia_static_initializers%': '<(skia_static_initializers)', | 229 'skia_static_initializers%': '<(skia_static_initializers)', |
| 236 'ios_sdk_version%': '6.0', | 230 'ios_sdk_version%': '6.0', |
| 237 'skia_win_debuggers_path%': '<(skia_win_debuggers_path)', | 231 'skia_win_debuggers_path%': '<(skia_win_debuggers_path)', |
| 238 'skia_run_pdfviewer_in_gm%': 0, | 232 'skia_run_pdfviewer_in_gm%': 0, |
| 239 'skia_disable_inlining%': 0, | 233 'skia_disable_inlining%': 0, |
| 240 'skia_moz2d%': 0, | 234 'skia_moz2d%': 0, |
| 241 'skia_is_bot%': '<!(python -c "import os; print os.environ.get(\'CHROME_HEAD
LESS\', 0)")', | 235 'skia_is_bot%': '<!(python -c "import os; print os.environ.get(\'CHROME_HEAD
LESS\', 0)")', |
| 242 'skia_egl%': '<(skia_egl)', | |
| 243 | 236 |
| 244 # These are referenced by our .gypi files that list files (e.g. core.gypi) | 237 # These are referenced by our .gypi files that list files (e.g. core.gypi) |
| 245 # | 238 # |
| 246 'skia_src_path%': '../src', | 239 'skia_src_path%': '../src', |
| 247 'skia_include_path%': '../include', | 240 'skia_include_path%': '../include', |
| 248 }, | 241 }, |
| 249 } | 242 } |
| OLD | NEW |