0001.patch (3136B)
1 From: Michael Froman <mfroman@mozilla.com> 2 Date: Tue, 7 Jun 2022 22:34:00 -0500 3 Subject: Bug 1772400 - pt2 - Rollup of various patches to 4 third_party/libwebrtc/third_party r?ng! 5 6 Several of these patches have been unindented to match the original content 7 of the files to make merging easier in the fast-foward work. 8 9 127ace4d8887 - Bug 1654112 - Tweak upstream gn files for Firefox build. 10 65562b1a98a3 - Bug 1654112 - minimize abseil-cpp build and usage in libwebrtc. 11 58f47eacaf10 - Bug 1654112 - deconflate the target and host architectures in libwebrtc build files 12 13 Differential Revision: https://phabricator.services.mozilla.com/D148809 14 Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/29bb1b6d7fc465aad44e15837e7b731bc40bc98a 15 --- 16 abseil-cpp/BUILD.gn | 24 +++++++++++++++++++++--- 17 abseil-cpp/absl.gni | 1 + 18 2 files changed, 22 insertions(+), 3 deletions(-) 19 20 diff --git a/abseil-cpp/BUILD.gn b/abseil-cpp/BUILD.gn 21 index 8b8bcfe69fe..97b460e4fd4 100644 22 --- a/abseil-cpp/BUILD.gn 23 +++ b/abseil-cpp/BUILD.gn 24 @@ -26,7 +26,7 @@ component("absl") { 25 public_configs = [ ":absl_component_build" ] 26 27 if (is_win && is_clang) { 28 - if (current_cpu == "x64") { 29 + if (target_cpu == "x64") { 30 if (is_debug) { 31 sources = [ "symbols_x64_dbg.def" ] 32 } else { 33 @@ -37,14 +37,14 @@ component("absl") { 34 } 35 } 36 } 37 - if (current_cpu == "x86") { 38 + if (target_cpu == "x86") { 39 if (is_debug) { 40 sources = [ "symbols_x86_dbg.def" ] 41 } else { 42 sources = [ "symbols_x86_rel.def" ] 43 } 44 } 45 - if (current_cpu == "arm64") { 46 + if (target_cpu == "arm64") { 47 if (is_debug) { 48 sources = [ "symbols_arm64_dbg.def" ] 49 } else { 50 @@ -56,6 +56,7 @@ component("absl") { 51 } 52 53 group("absl_component_deps") { 54 + if (false) { 55 public_deps = [ 56 "//third_party/abseil-cpp/absl/algorithm", 57 "//third_party/abseil-cpp/absl/algorithm:container", 58 @@ -125,6 +126,23 @@ group("absl_component_deps") { 59 # absl internal utilities used by protobuf. 60 "//third_party/abseil-cpp/absl/container:layout", 61 ] 62 + } else { 63 + public_deps = [ 64 + "//abseil-cpp/absl/algorithm:container", 65 + "//abseil-cpp/absl/base:nullability", 66 + "//abseil-cpp/absl/cleanup", 67 + "//abseil-cpp/absl/container:inlined_vector", 68 + "//abseil-cpp/absl/functional:any_invocable", 69 + "//abseil-cpp/absl/functional:bind_front", 70 + "//abseil-cpp/absl/strings", 71 + "//abseil-cpp/absl/strings:str_format", 72 + "//abseil-cpp/absl/strings:string_view", 73 + "//abseil-cpp/absl/types:optional", 74 + "//abseil-cpp/absl/types:span", 75 + "//abseil-cpp/absl/types:variant", 76 + "//abseil-cpp/absl/utility", 77 + ] 78 + } 79 80 if (is_component_build) { 81 public_deps += [ ":absl_full_deps" ] 82 diff --git a/abseil-cpp/absl.gni b/abseil-cpp/absl.gni 83 index 48e1ce78384..b19ac75675a 100644 84 --- a/abseil-cpp/absl.gni 85 +++ b/abseil-cpp/absl.gni 86 @@ -21,6 +21,7 @@ import("//build_overrides/build.gni") 87 88 declare_args() { 89 absl_build_tests = build_with_chromium 90 + moz_webrtc_build = true 91 } 92 93 template("absl_source_set") {