OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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 import("//build/config/chrome_build.gni") | 5 import("//build/config/chrome_build.gni") |
6 import("//build/config/features.gni") | 6 import("//build/config/features.gni") |
7 import("//chrome/version.gni") # TODO layering violation | 7 import("//chrome/version.gni") # TODO layering violation |
8 import("//media/cdm/ppapi/ppapi_cdm_adapter.gni") | 8 import("//media/cdm/ppapi/ppapi_cdm_adapter.gni") |
9 import("//third_party/widevine/cdm/widevine.gni") | 9 import("//third_party/widevine/cdm/widevine.gni") |
10 | 10 |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
60 outputs = [ | 60 outputs = [ |
61 "$root_gen_dir/widevine_cdm_version.h", | 61 "$root_gen_dir/widevine_cdm_version.h", |
62 ] | 62 ] |
63 } | 63 } |
64 | 64 |
65 # GYP version: third_party/widevine/cdm/widevine_cdm.gyp:widevinecdm | 65 # GYP version: third_party/widevine/cdm/widevine_cdm.gyp:widevinecdm |
66 if (widevine_cdm_binary_files != []) { | 66 if (widevine_cdm_binary_files != []) { |
67 copy("widevinecdm") { | 67 copy("widevinecdm") { |
68 sources = widevine_cdm_binary_files | 68 sources = widevine_cdm_binary_files |
69 outputs = [ | 69 outputs = [ |
70 "$root_out_dir/WidevineCdm/{{source_file_part}}", | 70 "$root_out_dir/{{source_file_part}}", |
71 ] | 71 ] |
72 | 72 |
73 # TODO(jrummell) | 73 # TODO(jrummell) |
74 # 'COPY_PHASE_STRIP': 'NO', | 74 # 'COPY_PHASE_STRIP': 'NO', |
75 } | 75 } |
76 } else if (enable_widevine && enable_pepper_cdms) { | 76 } else if (enable_widevine && enable_pepper_cdms) { |
77 assert(!is_chrome_branded, "Branded Chrome should have binary files to copy.") | 77 assert(!is_chrome_branded, "Branded Chrome should have binary files to copy.") |
78 assert(!is_android, "Android should not have enable_pepper_cdms.") | 78 assert(!is_android, "Android should not have enable_pepper_cdms.") |
79 shared_library("widevinecdm") { | 79 shared_library("widevinecdm") { |
80 output_dir = "$root_out_dir/WidevineCdm" | |
81 sources = [ | 80 sources = [ |
82 "//media/cdm/stub/stub_cdm.cc", | 81 "//media/cdm/stub/stub_cdm.cc", |
83 "//media/cdm/stub/stub_cdm.h", | 82 "//media/cdm/stub/stub_cdm.h", |
84 ] | 83 ] |
85 | 84 |
86 defines = [ "CDM_IMPLEMENTATION" ] | 85 defines = [ "CDM_IMPLEMENTATION" ] |
87 | 86 |
88 deps = [ | 87 deps = [ |
89 ":version_h", | 88 ":version_h", |
90 "//base", | 89 "//base", |
(...skipping 27 matching lines...) Expand all Loading... |
118 template_file = chrome_version_rc_template | 117 template_file = chrome_version_rc_template |
119 sources = [ | 118 sources = [ |
120 "BRANDING", | 119 "BRANDING", |
121 "widevinecdmadapter.ver", | 120 "widevinecdmadapter.ver", |
122 ] | 121 ] |
123 output = "$target_gen_dir/widevinecdmadapter_version.rc" | 122 output = "$target_gen_dir/widevinecdmadapter_version.rc" |
124 } | 123 } |
125 | 124 |
126 ppapi_cdm_adapter("widevinecdmadapter") { | 125 ppapi_cdm_adapter("widevinecdmadapter") { |
127 defines = [] | 126 defines = [] |
128 output_dir = "$root_out_dir/WidevineCdm" | |
129 deps = [ | 127 deps = [ |
130 ":version_h", | 128 ":version_h", |
131 ":widevinecdm", | 129 ":widevinecdm", |
132 ":widevinecdmadapter_resources", | 130 ":widevinecdmadapter_resources", |
133 ] | 131 ] |
134 | 132 |
135 if (is_linux) { | 133 if (is_linux) { |
136 ldflags = [ rebase_path("$root_out_dir/WidevineCdm/libwidevinecdm.so", | 134 ldflags = |
137 root_build_dir) ] | 135 [ rebase_path("$root_out_dir/libwidevinecdm.so", root_build_dir) ] |
138 } else if (is_win) { | 136 } else if (is_win) { |
139 ldflags = [ rebase_path("$root_out_dir/WidevineCdm/widevinecdm.dll.lib", | 137 ldflags = |
140 root_build_dir) ] | 138 [ rebase_path("$root_out_dir/widevinecdm.dll.lib", root_build_dir) ] |
141 } else if (is_mac) { | 139 } else if (is_mac) { |
142 ldflags = [ rebase_path("$root_out_dir/WidevineCdm/libwidevinecdm.dylib", | 140 ldflags = |
143 root_build_dir) ] | 141 [ rebase_path("$root_out_dir/libwidevinecdm.dylib", root_build_dir) ] |
144 } | 142 } |
145 } | 143 } |
146 } else { | 144 } else { |
147 # Placeholder when we're not compiling the adapter. | 145 # Placeholder when we're not compiling the adapter. |
148 group("widevinecdmadapter") { | 146 group("widevinecdmadapter") { |
149 } | 147 } |
150 } | 148 } |
151 | 149 |
152 # This target exists for tests to depend on that pulls in a runtime dependency | 150 # This target exists for tests to depend on that pulls in a runtime dependency |
153 # on the license server. | 151 # on the license server. |
154 source_set("widevine_test_license_server") { | 152 source_set("widevine_test_license_server") { |
155 if (is_chrome_branded && is_linux) { | 153 if (is_chrome_branded && is_linux) { |
156 deps = [ | 154 deps = [ |
157 # TODO(jrummell) | 155 # TODO(jrummell) |
158 # This target should be removed and targets should have data_deps on this
target: | 156 # This target should be removed and targets should have data_deps on this
target: |
159 #"//third_party/widevine/test/license_server/license_server.gyp:test_licen
se_server" | 157 #"//third_party/widevine/test/license_server/license_server.gyp:test_licen
se_server" |
160 ] | 158 ] |
161 } | 159 } |
162 } | 160 } |
OLD | NEW |