Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(592)

Side by Side Diff: third_party/widevine/cdm/widevine_cdm.gyp

Issue 1989893004: media: Use platform specific folders for CDMs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: specify both paths in chrome.release Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 # If enable_widevine==1 then create a dummy widevinecdm. On Win/Mac 53 # If enable_widevine==1 then create a dummy widevinecdm. On Win/Mac
54 # the component updater will get the latest version and use it. 54 # the component updater will get the latest version and use it.
55 # Other systems are not currently supported. 55 # Other systems are not currently supported.
56 'widevine_cdm_version_h_file%': 56 'widevine_cdm_version_h_file%':
57 'stub/widevine_cdm_version.h', 57 'stub/widevine_cdm_version.h',
58 }], 58 }],
59 ], 59 ],
60 }, 60 },
61 'includes': [ 61 'includes': [
62 '../../../build/util/version.gypi', 62 '../../../build/util/version.gypi',
63 '../../../media/cdm_paths.gypi',
63 ], 64 ],
64
65 # Always provide a target, so we can put the logic about whether there's 65 # Always provide a target, so we can put the logic about whether there's
66 # anything to be done in this file (instead of a higher-level .gyp file). 66 # anything to be done in this file (instead of a higher-level .gyp file).
67 'targets': [ 67 'targets': [
68 { 68 {
69 # GN version: //third_party/widevine/cdm:widevinecdmadapter_resources 69 # GN version: //third_party/widevine/cdm:widevinecdmadapter_resources
70 'target_name': 'widevinecdmadapter_resources', 70 'target_name': 'widevinecdmadapter_resources',
71 'type': 'none', 71 'type': 'none',
72 'variables': { 72 'variables': {
73 'output_dir': '.', 73 'output_dir': '.',
74 'branding_path': '../../../chrome/app/theme/<(branding_path_component)/B RANDING', 74 'branding_path': '../../../chrome/app/theme/<(branding_path_component)/B RANDING',
75 'template_input_path': '../../../chrome/app/chrome_version.rc.version', 75 'template_input_path': '../../../chrome/app/chrome_version.rc.version',
76 'extra_variable_files_arguments': [ '-f', 'BRANDING' ], 76 'extra_variable_files_arguments': [ '-f', 'BRANDING' ],
77 'extra_variable_files': [ 'BRANDING' ], # NOTE: matches that above 77 'extra_variable_files': [ 'BRANDING' ], # NOTE: matches that above
78 }, 78 },
79 'sources': [ 79 'sources': [
80 'widevinecdmadapter.ver', 80 'widevinecdmadapter.ver',
81 ], 81 ],
82 'includes': [ 82 'includes': [
83 '../../../chrome/version_resource_rules.gypi', 83 '../../../chrome/version_resource_rules.gypi',
84 ], 84 ],
85 }, 85 },
86 { 86 {
87 # GN version: //third_party/widevine/cdm:widevinecdmadapter 87 'target_name': 'widevinecdmadapter_binary',
88 'target_name': 'widevinecdmadapter', 88 'product_name': 'widevinecdmadapter',
89 'type': 'none', 89 'type': 'none',
90 'conditions': [ 90 'conditions': [
91 [ '(branding == "Chrome" or enable_widevine == 1) and enable_pepper_cdms == 1', { 91 [ '(branding == "Chrome" or enable_widevine == 1) and enable_pepper_cdms == 1', {
92 'dependencies': [ 92 'dependencies': [
93 '<(DEPTH)/ppapi/ppapi.gyp:ppapi_cpp', 93 '<(DEPTH)/ppapi/ppapi.gyp:ppapi_cpp',
94 '<(DEPTH)/media/media_cdm_adapter.gyp:cdmadapter', 94 '<(DEPTH)/media/media_cdm_adapter.gyp:cdmadapter',
95 'widevine_cdm_version_h', 95 'widevine_cdm_version_h',
96 'widevinecdm', 96 'widevinecdm',
97 'widevinecdmadapter_resources', 97 'widevinecdmadapter_resources',
98 ], 98 ],
99 'sources': [ 99 'sources': [
100 '<(SHARED_INTERMEDIATE_DIR)/widevinecdmadapter_version.rc', 100 '<(SHARED_INTERMEDIATE_DIR)/widevinecdmadapter_version.rc',
101 ], 101 ],
102 'conditions': [ 102 'conditions': [
103 [ 'os_posix == 1 and OS != "mac"', { 103 [ 'os_posix == 1 and OS != "mac"', {
104 'libraries': [ 104 'libraries': [
105 '-lrt', 105 '-lrt',
106 # Copied/created by widevinecdm. 106 # Copied/created by widevinecdm.
107 '<(PRODUCT_DIR)/libwidevinecdm.so', 107 '<(PRODUCT_DIR)/<(widevine_cdm_path)/libwidevinecdm.so',
108 ], 108 ],
109 }], 109 }],
110 [ 'OS == "win"', { 110 [ 'OS == "win"', {
111 'libraries': [ 111 'libraries': [
112 # Copied/created by widevinecdm. 112 # Copied/created by widevinecdm.
113 '<(PRODUCT_DIR)/widevinecdm.dll.lib', 113 '<(PRODUCT_DIR)/<(widevine_cdm_path)/widevinecdm.dll.lib',
114 ], 114 ],
115 }], 115 }],
116 [ 'OS == "mac"', { 116 [ 'OS == "mac"', {
117 'libraries': [ 117 'libraries': [
118 # Copied/created by widevinecdm. 118 # Copied/created by widevinecdm.
119 '<(PRODUCT_DIR)/libwidevinecdm.dylib', 119 '<(PRODUCT_DIR)/<(widevine_cdm_path)/libwidevinecdm.dylib',
120 ], 120 ],
121 }, {
122 # Put Widevine CDM adapter to the correct path directly except
123 # for mac. On mac strip_save_dsym doesn't work with product_dir
124 # so we rely on "widevinecdmadapter" target to copy it over.
125 # See http://crbug.com/611990
126 'product_dir': '<(PRODUCT_DIR)/<(widevine_cdm_path)',
121 }], 127 }],
122 ], 128 ],
123 }], 129 }],
124 ], 130 ],
125 }, 131 },
126 { 132 {
133 # GN version: //third_party/widevine/cdm:widevinecdmadapter
134 # On Mac this copies the widevinecdmadapter binary to
135 # <(widevine_cdm_path). On all other platforms the binary is already
136 # in <(widevine_cdm_path). See "product_dir" above.
137 'target_name': 'widevinecdmadapter',
138 'type': 'none',
139 'dependencies': [
140 'widevinecdmadapter_binary',
141 ],
142 'conditions': [
143 [ '(branding == "Chrome" or enable_widevine == 1) and enable_pepper_cdms == 1 and OS == "mac"', {
144 'copies': [{
145 'destination': '<(PRODUCT_DIR)/<(widevine_cdm_path)',
146 'files': [ '<(PRODUCT_DIR)/widevinecdmadapter.plugin' ],
147 }],
148 }],
149 ],
150 },
151 {
127 # GN version: //third_party/widevine/cdm:version_h 152 # GN version: //third_party/widevine/cdm:version_h
128 'target_name': 'widevine_cdm_version_h', 153 'target_name': 'widevine_cdm_version_h',
129 'type': 'none', 154 'type': 'none',
130 'copies': [{ 155 'copies': [{
131 'destination': '<(SHARED_INTERMEDIATE_DIR)', 156 'destination': '<(SHARED_INTERMEDIATE_DIR)',
132 'files': [ '<(widevine_cdm_version_h_file)' ], 157 'files': [ '<(widevine_cdm_version_h_file)' ],
133 }], 158 }],
134 }, 159 },
135 { 160 {
136 # GN version: //third_party/widevine/cdm:widevinecdm 161 # GN version: //third_party/widevine/cdm:widevinecdm
137 'target_name': 'widevinecdm', 162 'target_name': 'widevinecdm',
138 'type': 'none', 163 'type': 'none',
139 'conditions': [ 164 'conditions': [
140 [ 'branding == "Chrome"', { 165 [ 'branding == "Chrome"', {
141 'conditions': [ 166 'conditions': [
142 [ 'OS=="mac"', { 167 [ 'OS=="mac"', {
143 'xcode_settings': { 168 'xcode_settings': {
144 'COPY_PHASE_STRIP': 'NO', 169 'COPY_PHASE_STRIP': 'NO',
145 } 170 }
146 }], 171 }],
147 ], 172 ],
148 'copies': [{ 173 'copies': [{
149 # TODO(ddorwin): Do we need a sub-directory? We either need a 174 'destination': '<(PRODUCT_DIR)/<(widevine_cdm_path)',
150 # sub-directory or to rename manifest.json before we can copy it.
151 'destination': '<(PRODUCT_DIR)',
152 'files': [ '<@(widevine_cdm_binary_files)' ], 175 'files': [ '<@(widevine_cdm_binary_files)' ],
153 }], 176 }],
154 }], 177 }],
155 [ 'branding != "Chrome" and enable_widevine == 1', { 178 [ 'branding != "Chrome" and enable_widevine == 1', {
179 'product_dir': '<(PRODUCT_DIR)/<(widevine_cdm_path)',
156 'conditions': [ 180 'conditions': [
157 ['os_posix == 1 and OS != "mac"', { 181 ['os_posix == 1 and OS != "mac"', {
158 'type': 'loadable_module', 182 'type': 'loadable_module',
159 # Note that this causes the binary to be put in PRODUCT_DIR 183 # This causes the binary to be put in
160 # instead of lib/. This matches what happens in the copy step 184 # <(PRODUCT_DIR)/<(widevine_cdm_path) instead of lib/.
161 # above. 185 # This matches what happens in the copy step above.
162 }], 186 }],
163 ['OS == "mac" or OS == "win"', { 187 ['OS == "mac" or OS == "win"', {
164 'type': 'shared_library', 188 'type': 'shared_library',
165 }], 189 }],
166 ['OS == "mac"', { 190 ['OS == "mac"', {
167 'xcode_settings': { 191 'xcode_settings': {
168 'DYLIB_INSTALL_NAME_BASE': '@loader_path', 192 'DYLIB_INSTALL_NAME_BASE': '@loader_path',
169 }, 193 },
170 }], 194 }],
171 ], 195 ],
(...skipping 16 matching lines...) Expand all
188 'conditions': [ 212 'conditions': [
189 [ 'branding == "Chrome" and OS == "linux"', { 213 [ 'branding == "Chrome" and OS == "linux"', {
190 'dependencies': [ 214 'dependencies': [
191 '<(DEPTH)/third_party/widevine/test/license_server/license_server.gy p:test_license_server', 215 '<(DEPTH)/third_party/widevine/test/license_server/license_server.gy p:test_license_server',
192 ], 216 ],
193 }], 217 }],
194 ], 218 ],
195 }, 219 },
196 ], 220 ],
197 } 221 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698