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

Unified Diff: third_party/widevine/cdm/BUILD.gn

Issue 949233003: Fix official build in GN (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@random
Patch Set: remove ppapi dep Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/third_party/nss/ssl/BUILD.gn ('k') | third_party/widevine/cdm/widevine_cdm.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/widevine/cdm/BUILD.gn
diff --git a/third_party/widevine/cdm/BUILD.gn b/third_party/widevine/cdm/BUILD.gn
index d32229446eb962303b8758a6e58905c12794bce9..3fce784ad36a59bdcca36b6239cac6b1cb12110a 100644
--- a/third_party/widevine/cdm/BUILD.gn
+++ b/third_party/widevine/cdm/BUILD.gn
@@ -2,6 +2,10 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
+import("//build/config/features.gni")
+import("//chrome/version.gni") # TODO layering violation
+import("//media/cdm/ppapi/cdm_adapter.gni")
+
widevine_arch = current_cpu
if (widevine_arch == "x86") {
widevine_arch = "ia32"
@@ -70,26 +74,46 @@ if (widevine_cdm_binary_files == []) {
}
}
-source_set("adapter") {
- if (is_chrome_branded) {
+if (is_chrome_branded && enable_pepper_cdms) {
+ adapter_resource_file = "$target_gen_dir/widevinecdmadapter_version.rc"
+
+ # Produce the .rc file.
+ process_version("adapter_resources") {
+ visibility = [ ":*" ]
+ sources = [
+ "BRANDING",
+ "widevinecdmadapter.ver",
+ ]
+ output = adapter_resource_file
+ }
+
+ cdm_adapter("adapter") {
+ sources = [
+ adapter_resource_file,
+ ]
deps = [
- ":version_h",
+ ":adapter_resources",
":binaries",
+ ":version_h",
"//ppapi/cpp",
-
- #'<(DEPTH)/media/media_cdm_adapter.gyp:cdmadapter', TODO(GYP)
]
if (is_linux) {
- libs = [ rebase_path("$root_out_dir/libwidevinecdm.so", root_build_dir) ]
+ ldflags =
+ [ rebase_path("$root_out_dir/libwidevinecdm.so", root_build_dir) ]
+ libs = [ "rt" ]
} else if (is_win) {
- libs =
+ ldflags =
[ rebase_path("$root_out_dir/widevinecdm.dll.lib", root_build_dir) ]
} else if (is_mac) {
- libs =
+ ldflags =
[ rebase_path("$root_out_dir/libwidevinecdm.dylib", root_build_dir) ]
}
}
+} else {
+ # Placeholder when we're not compiling the adapter.
+ group("adapter") {
+ }
}
# This target exists for tests to depend on that pulls in a runtime dependency
« no previous file with comments | « net/third_party/nss/ssl/BUILD.gn ('k') | third_party/widevine/cdm/widevine_cdm.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698