Matlab files extension is the same as ObjC, which is .m
This makes clang-format think that those files are ObjC and then it
wrongly formats them, leading to output that doesn't compile at all.
It's a known issue and the solution is to disable it in Matlab files.
I don't want to disable ObjC in whole folders, because of 2 reasons:
1) I want ObjC to be properly formatted if new files are added in the
future
2) C++ header files are interpreted as ObjC and it will disable their
formatting
According to clang documentation
(https://clang.llvm.org/docs/ClangFormatStyleOptions.html#disabling-formatting-on-a-piece-of-code), we can disable formatting inline.
However, comments in Matlab are prefixed with `%` and not `//`, so I
thought of a kinda hacky solution, which is `% // clang-format off`, and
it works perfectly.
No-Iwyu: Includes didn't change and it isn't related to formatting
Bug: webrtc:42225392
Change-Id: I281462fd1aecd3ff0428e6ee974514ebabc696ec
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/374060
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43700}
for easy integration with
git diff-tree --no-commit-id --name-only -r HEAD
which gets the list of files in a commit
BUG=webrtc:42226242
Change-Id: I6e80d0f13e4f182d7c0c9c8ea971f6e48fbaae76
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/370461
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@meta.com>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43589}
The Android bots and the libfuzzer bots have an indirect dependency on base. This CL downloads the rust toolchain for these bots so that rust can be used in Chromium base/ without guards to prevent WebRTC from breaking.
Change-Id: I81e0a32827e8eee29f333d933d0fb21dc0b7dc23
Bug: None
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367921
Commit-Queue: Jeremy Leconte <jleconte@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43384}
This is to avoid a dependency on Chromium //base on bots that don't need it:
1bd0da6657:libfuzzer/BUILD.gn;l=164
Bug: None
Change-Id: Idf3ef2a313641abcd3741e0ef7b2fac61c629068
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367640
Commit-Queue: Jeremy Leconte <jleconte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43360}
The script can't find the `find_depot_tools` module if this repo is
checked out under chromium/src.
Bug: b:364177019
Change-Id: I75997a41e1a9732d0e9f6567b00c86784c7b4ce9
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/361680
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Henrik Andreassson <henrika@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42954}
gmock and gtest includes are replaced in the script but this wasn't applied to the 'CHECK_MODE' causing false error report.
nit: Usage is printed when no arguments are provided.
Change-Id: I418a17b998934b0079f5bf19513097481f35aa70
Bug: b/236227627
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/361400
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Jeremy Leconte <jleconte@google.com>
Cr-Commit-Position: refs/heads/main@{#42927}
-w allow to specify the working directory.
-c sets the exit code to 1 if there are changes to apply.
This flags are added so that the script can be running from a CQ bot.
Change-Id: I725a530b4dbbff26d4060435e90aaa66a75e572f
Bug: b/236227627
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/360980
Commit-Queue: Jeremy Leconte <jleconte@google.com>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42897}
RollError: WebRTC DEPS entries are missing from Chromium: ['src/third_party/android_build_tools/aapt2', 'src/third_party/hamcrest', 'src/third_party/icu4j', 'src/third_party/kotlin_stdlib'].
Remove them or add them to either WEBRTC_ONLY_DEPS or DONT_AUTOROLL_THESE.
Bug: None
Change-Id: I69b4912e13cb7b84ffd822856e2273594a52717c
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/360420
Commit-Queue: Jeremy Leconte <jleconte@webrtc.org>
Auto-Submit: Christoffer Dewerin <jansson@google.com>
Reviewed-by: Jeremy Leconte <jleconte@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42844}
Unfortunately, clangd's include-cleaner has a smaller set of
customization features and does not allow us to set custom mappings for
certain include paths. Instead, add some postprocessing to our internal
wrapper on top of it (`apply-include-cleaner`) to handle gtest/gmock
include paths
Bug: webrtc:42226242
Change-Id: I65e4f73bb1b762bf2da1fb0f9a520bdd980b64bd
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/359161
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Dor Hen <dorhen@meta.com>
Cr-Commit-Position: refs/heads/main@{#42774}
If the webrtc/src repo is checked out in a directory that isn't named
"src", FindSrcDirPath will loop forever. Instead of trying to find the
repo root, just use the location of the scripts and work out the
root with os.pardir.
Bug: b/333744051
Change-Id: Ifccdb85d3f9c7cb27ca57cc0b7bb96adf783660d
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/357980
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
Cr-Commit-Position: refs/heads/main@{#42701}
Trying to change any one of these files will make presubmits
complain that the file isn't properly formatted. Format and rename
variables to be PEP-8 and pylint compliant.
Bug: b/333744051
Change-Id: I8dd4f7f05e52777a62b49659a3c264fe28926539
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/358160
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42700}
This prevents the new default (noble) to be applied. And before
the Chromium roll that updates this to noble, focal is the
default.
Bug: b/345700252
Change-Id: Ia20bc4ec1178a23ab93598cfb53bfd2189490932
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/354074
Reviewed-by: Christoffer Dewerin <jansson@webrtc.org>
Commit-Queue: Christoffer Dewerin <jansson@webrtc.org>
Auto-Submit: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42454}
BWE logging has as far as I know know been used for a long time. RTC event logs are the prefered method of logging.
Removed since it causes some BUILD pain.
For debugging the metrics API https://source.chromium.org/chromium/chromium/src/+/main:third_party/webrtc/api/test/metrics/ can be used instead.
Bug: webrtc:343347276
Change-Id: I046b58d880faabfadbc22269b0392fdd644155fc
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/352602
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Auto-Submit: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Jeremy Leconte <jleconte@webrtc.org>
Commit-Queue: Jeremy Leconte <jleconte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42402}
The invocation is supposed to be at the project top-level and not from the build folder as it can otherwise hide Abseil headers.
Bug: webrtc:15874
Change-Id: Iaa481dce8dc08b0d2e66e9170627e8963f7c0db9
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/351120
Commit-Queue: Florent Castelli <orphis@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42359}
While GCS dependencies aren't currently used, their support is required
to prevent the autoroller from breaking when encountering GCS dep types.
Bug: None
Change-Id: I58601e9eaeb8372058da4d4ee02cd2ca589e02c7
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349740
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42222}
This is the first new style trace event so this CL adds and updates
WebRTCs Perfetto configuration.
* Changes all #includes to target "third_party/perfetto". Added this
to DEPS.
* Expose the Perfetto public config in the "tracing" group using
an all_dependent_configs statement. This means the config is included
in all parts that include the "//:tracing" group. However, direct
perfetto includes are banned per DEPS.
* In order to expose Perfetto types (ie Flow/TerminatingFlow) the
perfetto headers are a dependancy on all targets. This should not
affect binary size as these are not used when perfetto is not enabled
and will not be linked.
Bug: b/42226290
Change-Id: I5711d81dae95ee907cbcd41bf1ee9b55d2ec595c
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349161
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Evan Shrubsole <eshr@google.com>
Cr-Commit-Position: refs/heads/main@{#42197}
This adds Perfetto support to WebRTC with a GN flag rtc_use_perfetto.
The configuration of perfetto depends on whether or not webrtc is
build within Chrome or not. When in Chrome, WebRTC will depend on
//third_party/perfetto:libperfetto. When building standalone, specific includes required for Perfetto are exposed with the library webrtc_libperfetto.
The perfetto trace API is exposed with a header export in
trace_event.h which is used instead of the legacy API.
The addition of Perfetto means there are 4 compilation modes for
tracing in WebRTC,
1. No tracing implementation.
2. Legacy tracing (AddTraceEvent/GetCategoryEnabled).
3.a. Perfetto statically linked (webrtc_libperfetto).
3.b. Perfetto in Chrome (Chrome's libperfetto).
This CL removes the tracing expectations from
rtc_stats_integrationtest.cc because those directly used the old API.
Integration into Chrome is a follow up CL which depends on
https://chromium-review.googlesource.com/c/chromium/src/+/5471691.
Tested: Ran Chrome with Perfetto and traces appear. WebRTC Unit test tracing working: https://ui.perfetto.dev/#!?s=04ea2613ea36b814394639a1ec4b60be5b5097527f1a485995ecc13469885468
Bug: webrtc:15917
Change-Id: I537d79dc247c2b759689910c621087286a4d8fdc
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/347880
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Auto-Submit: Evan Shrubsole <eshr@google.com>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Mikhail Khokhlov <khokhlov@google.com>
Cr-Commit-Position: refs/heads/main@{#42166}
Also change the generation of compile_commands.json so that it
does not include reclient arguments.
Bug: webrtc:15874
Change-Id: I1bc2e7a8768a3467d31528d584f7e70d946a3301
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/347900
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42110}
Since iwyu is now deprecated, we need to enable use of include-cleaner.
This approach gives some error messages when running, but does the job.
Bug: webrtc:15874
Change-Id: I431deef0f2e5ce99eb256a4d82aa32769ae58b41
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/347642
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42085}
The intent is to catch compile errors when tracing is turned off.
Bug: None
Change-Id: I48a42e53e7bd8053984b7d0687b1f6abe538cba1
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/333760
Reviewed-by: Christoffer Dewerin <jansson@google.com>
Auto-Submit: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#41474}
This test drives the new tools_webrtc/remove_extra_namespace.py tool.
Bug: None
Change-Id: I9b590aa1213e4cace2d64d555f4dafd893f03606
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/327021
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#41141}