| OLD | NEW |
| 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 { | 5 { |
| 6 'variables': { | 6 'variables': { |
| 7 # Allow widevinecdmadapter to be built in Chromium. | 7 # Allow widevinecdmadapter to be built in Chromium. |
| 8 'variables': { | 8 'variables': { |
| 9 'enable_widevine%': 0, | 9 'enable_widevine%': 0, |
| 10 }, | 10 }, |
| (...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 172 'conditions': [ | 172 'conditions': [ |
| 173 [ 'widevine_cdm_manifest_file != []', { | 173 [ 'widevine_cdm_manifest_file != []', { |
| 174 'copies': [{ | 174 'copies': [{ |
| 175 'destination': '<(PRODUCT_DIR)/WidevineCdm', | 175 'destination': '<(PRODUCT_DIR)/WidevineCdm', |
| 176 'files': [ '<(widevine_cdm_manifest_file)' ], | 176 'files': [ '<(widevine_cdm_manifest_file)' ], |
| 177 }], | 177 }], |
| 178 }], | 178 }], |
| 179 ], | 179 ], |
| 180 }, | 180 }, |
| 181 { | 181 { |
| 182 'target_name': 'widevinecdm_binary', | |
| 183 'product_name': 'widevinecdm', | |
| 184 'type': 'none', | |
| 185 'conditions': [ | |
| 186 ['os_posix == 1 and OS != "mac"', { | |
| 187 'type': 'loadable_module', | |
| 188 }], | |
| 189 ['OS == "mac" or OS == "win"', { | |
| 190 'type': 'shared_library', | |
| 191 }], | |
| 192 ['OS == "mac"', { | |
| 193 'xcode_settings': { | |
| 194 'DYLIB_INSTALL_NAME_BASE': '@loader_path', | |
| 195 }, | |
| 196 }, { | |
| 197 # Put Widevine CDM in the correct path directly except | |
| 198 # for mac. On mac strip_save_dsym doesn't work with product_dir | |
| 199 # so we rely on the "widevinecdm" target to copy it over. | |
| 200 # See http://crbug.com/611990 | |
| 201 'product_dir': '<(PRODUCT_DIR)/<(widevine_cdm_path)', | |
| 202 }], | |
| 203 ], | |
| 204 'defines': ['CDM_IMPLEMENTATION'], | |
| 205 'dependencies': [ | |
| 206 'widevine_cdm_version_h', | |
| 207 '<(DEPTH)/base/base.gyp:base', | |
| 208 ], | |
| 209 'sources': [ | |
| 210 '<(DEPTH)/media/cdm/stub/stub_cdm.cc', | |
| 211 '<(DEPTH)/media/cdm/stub/stub_cdm.h', | |
| 212 ], | |
| 213 }, | |
| 214 { | |
| 215 # GN version: //third_party/widevine/cdm:widevinecdm | 182 # GN version: //third_party/widevine/cdm:widevinecdm |
| 216 'target_name': 'widevinecdm', | 183 'target_name': 'widevinecdm', |
| 217 'type': 'none', | 184 'type': 'none', |
| 218 'conditions': [ | 185 'conditions': [ |
| 219 [ 'branding == "Chrome"', { | 186 [ 'branding == "Chrome"', { |
| 220 'conditions': [ | 187 'conditions': [ |
| 221 [ 'OS=="mac"', { | 188 [ 'OS=="mac"', { |
| 222 'xcode_settings': { | 189 'xcode_settings': { |
| 223 'COPY_PHASE_STRIP': 'NO', | 190 'COPY_PHASE_STRIP': 'NO', |
| 224 } | 191 } |
| 225 }], | 192 }], |
| 226 ], | 193 ], |
| 227 'copies': [{ | 194 'copies': [{ |
| 228 'destination': '<(PRODUCT_DIR)/<(widevine_cdm_path)', | 195 'destination': '<(PRODUCT_DIR)/<(widevine_cdm_path)', |
| 229 'files': [ '<@(widevine_cdm_binary_files)' ], | 196 'files': [ '<@(widevine_cdm_binary_files)' ], |
| 230 }], | 197 }], |
| 231 }], | 198 }], |
| 232 [ 'branding != "Chrome" and enable_widevine == 1', { | 199 [ 'branding != "Chrome" and enable_widevine == 1', { |
| 233 # On Mac this copies the widevinecdm binary to <(widevine_cdm_path). | 200 'product_dir': '<(PRODUCT_DIR)/<(widevine_cdm_path)', |
| 234 # On other platforms the binary is already in <(widevine_cdm_path). | 201 'conditions': [ |
| 235 # See "widevinecdm_binary" above. | 202 ['os_posix == 1 and OS != "mac"', { |
| 203 'type': 'loadable_module', |
| 204 # This causes the binary to be put in |
| 205 # <(PRODUCT_DIR)/<(widevine_cdm_path) instead of lib/. |
| 206 # This matches what happens in the copy step above. |
| 207 }], |
| 208 ['OS == "mac" or OS == "win"', { |
| 209 'type': 'shared_library', |
| 210 }], |
| 211 ['OS == "mac"', { |
| 212 'xcode_settings': { |
| 213 'DYLIB_INSTALL_NAME_BASE': '@loader_path', |
| 214 }, |
| 215 }], |
| 216 ], |
| 217 'defines': ['CDM_IMPLEMENTATION'], |
| 236 'dependencies': [ | 218 'dependencies': [ |
| 237 'widevinecdm_binary', | 219 'widevine_cdm_version_h', |
| 220 '<(DEPTH)/base/base.gyp:base', |
| 238 ], | 221 ], |
| 239 'conditions': [ | 222 'sources': [ |
| 240 ['OS == "mac"', { | 223 '<(DEPTH)/media/cdm/stub/stub_cdm.cc', |
| 241 'copies': [{ | 224 '<(DEPTH)/media/cdm/stub/stub_cdm.h', |
| 242 'destination': '<(PRODUCT_DIR)/<(widevine_cdm_path)', | |
| 243 'files': [ '<(PRODUCT_DIR)/libwidevinecdm.dylib' ], | |
| 244 }], | |
| 245 }], | |
| 246 ], | 225 ], |
| 247 }], | 226 }], |
| 248 ], | 227 ], |
| 249 }, | 228 }, |
| 250 { | 229 { |
| 251 # GN version: //third_party/widevine/cdm:widevine_test_license_server | 230 # GN version: //third_party/widevine/cdm:widevine_test_license_server |
| 252 'target_name': 'widevine_test_license_server', | 231 'target_name': 'widevine_test_license_server', |
| 253 'type': 'none', | 232 'type': 'none', |
| 254 'conditions': [ | 233 'conditions': [ |
| 255 [ 'branding == "Chrome" and OS == "linux"', { | 234 [ 'branding == "Chrome" and OS == "linux"', { |
| 256 'dependencies': [ | 235 'dependencies': [ |
| 257 '<(DEPTH)/third_party/widevine/test/license_server/license_server.gy
p:test_license_server', | 236 '<(DEPTH)/third_party/widevine/test/license_server/license_server.gy
p:test_license_server', |
| 258 ], | 237 ], |
| 259 }], | 238 }], |
| 260 ], | 239 ], |
| 261 }, | 240 }, |
| 262 ], | 241 ], |
| 263 } | 242 } |
| OLD | NEW |