File: 0119.patch

package info (click to toggle)
thunderbird 1%3A143.0.1-1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 4,703,968 kB
  • sloc: cpp: 7,770,492; javascript: 5,943,842; ansic: 3,918,754; python: 1,418,263; xml: 653,354; asm: 474,045; java: 183,079; sh: 111,238; makefile: 20,410; perl: 14,359; objc: 13,059; yacc: 4,583; pascal: 3,405; lex: 1,720; ruby: 999; exp: 762; sql: 715; awk: 580; php: 436; lisp: 430; sed: 69; csh: 10
file content (100 lines) | stat: -rw-r--r-- 3,290 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
From: Michael Froman <mfroman@mozilla.com>
Date: Thu, 10 Oct 2024 13:42:00 +0000
Subject: Bug 1921707 - webrtc.gni - filter out '//third_party/abseil-cpp/'
 deps r=ng,webrtc-reviewers

Differential Revision: https://phabricator.services.mozilla.com/D224079
Mercurial Revision: https://hg.mozilla.org/mozilla-central/rev/45b99d1ba95b46896506de1c7dd92f19e4dc9207
---
 webrtc.gni | 71 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 71 insertions(+)

diff --git a/webrtc.gni b/webrtc.gni
index ffecd38d5a..3cc7d4777a 100644
--- a/webrtc.gni
+++ b/webrtc.gni
@@ -696,6 +696,36 @@ template("rtc_source_set") {
         deps += [ "//third_party/abseil-cpp:absl" ]
       }
     }
+
+    # Rather than widespread changes to most, if not all, BUILD.gn files
+    # we'll do some filtering on dependencies here.
+    if (build_with_mozilla && defined(deps)) {
+      # Now that abseil-cpp is moved to Mozilla's third_party directory
+      # we remove all the abseil-cpp dependency listings so moz.build
+      # generation succeed.
+      filtered_deps = []
+      foreach (dep, deps) {
+        newdep = string_replace(dep, "//third_party/abseil-cpp/", "")
+        if (newdep == dep) {
+          filtered_deps += [ dep ]
+        }
+      }
+      deps = []
+      deps = filtered_deps
+
+      # We don't build any of the test code, but many of the test
+      # targets list gtest/gmock as a dependency.  We can simply
+      # filter them out here.
+      filtered_deps = []
+      foreach (dep, deps) {
+        newdep = string_replace(dep, "//testing/g", "")
+        if (newdep == dep) {
+          filtered_deps += [ dep ]
+        }
+      }
+      deps = []
+      deps = filtered_deps
+    }
   }
 }
 
@@ -930,6 +960,47 @@ template("rtc_library") {
         deps += [ "//third_party/abseil-cpp:absl" ]
       }
     }
+
+    # Rather than widespread changes to most, if not all, BUILD.gn files
+    # we'll do some filtering on dependencies here.
+    if (build_with_mozilla && defined(deps)) {
+      # Now that abseil-cpp is moved to Mozilla's third_party directory
+      # we remove all the abseil-cpp dependency listings so moz.build
+      # generation succeed.
+      filtered_deps = []
+      foreach (dep, deps) {
+        newdep = string_replace(dep, "//third_party/abseil-cpp/", "")
+        if (newdep == dep) {
+          filtered_deps += [ dep ]
+        }
+      }
+      deps = []
+      deps = filtered_deps
+
+      # We don't build any of the test code, but many of the test
+      # targets list gtest/gmock as a dependency.  We can simply
+      # filter them out here.
+      filtered_deps = []
+      foreach (dep, deps) {
+        newdep = string_replace(dep, "//testing/g", "")
+        if (newdep == dep) {
+          filtered_deps += [ dep ]
+        }
+      }
+      deps = []
+      deps = filtered_deps
+
+      # Moving the google build directory requires looking for libwebrtc's
+      # third_party dependencies under libwebrtc/third_party instead of
+      # simply third_party.
+      modified_deps = []
+      foreach (dep, deps) {
+        newdep = string_replace(dep, "//third_party/", "//libwebrtc/third_party/")
+        modified_deps += [ newdep ]
+      }
+      deps = []
+      deps = modified_deps
+    }
   }
 }